1
0
mirror of https://gitlab.gnome.org/GNOME/evince synced 2024-06-28 13:44:46 +00:00

sidebar-annotations: avoid crash when deleting annotation

avoid it by preventing running our GtkTreeSelection 'changed'
handler when triggered by gtk_tree_store_clear() in the callback
for loading the new annotations.

Fixes #2022
This commit is contained in:
Nelson Benítez León 2024-02-23 12:51:30 +00:00
parent 07d12131bd
commit 4ad3b2c40a

View File

@ -356,7 +356,9 @@ job_finished_callback (EvJobAnnots *job,
G_CALLBACK (sidebar_tree_button_press_cb),
sidebar_annots);
g_signal_handler_block (selection, priv->selection_changed_id);
gtk_tree_store_clear (model);
g_signal_handler_unblock (selection, priv->selection_changed_id);
for (l = job->annots; l; l = g_list_next (l)) {
EvMappingList *mapping_list;