From a1810433ed1c3cb35fa32d5604cad8e194175712 Mon Sep 17 00:00:00 2001 From: Georges Basile Stavracas Neto Date: Wed, 13 Sep 2023 09:15:10 -0300 Subject: [PATCH] core/timeline: Don't excise events from queue When removing the last subscriber (something that can happen when closing the main window), GcalTimeline clears the event queue. But that leaves us in an inconsistent state, as we don't process any of the potentially removed events. Don't do that. Related: https://gitlab.gnome.org/GNOME/gnome-calendar/-/issues/1087 --- src/core/gcal-timeline.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/src/core/gcal-timeline.c b/src/core/gcal-timeline.c index b982f4c9..51c936ec 100644 --- a/src/core/gcal-timeline.c +++ b/src/core/gcal-timeline.c @@ -1072,9 +1072,6 @@ gcal_timeline_remove_subscriber (GcalTimeline *self, g_signal_handlers_disconnect_by_func (subscriber, on_subscriber_range_changed_cb, self); g_hash_table_remove (self->subscribers, subscriber); - if (g_hash_table_size (self->subscribers) == 0) - g_queue_clear_full (self->event_queue, (GDestroyNotify) queue_data_free); - gcal_range_tree_remove_data (self->subscriber_ranges, subscriber); update_range (self);