From 38e355c3b1e56d9a3bf15ede58786163ab847615 Mon Sep 17 00:00:00 2001 From: Trystan Mata Date: Tue, 2 Sep 2025 14:11:25 +0200 Subject: [PATCH] calendar-navigation-button: Fix active-date reference Increase active-date reference count so the button and the window have their own reference. This fix the reference issue while the window is finalizing. Part-of: --- src/gui/gcal-calendar-navigation-button.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/gui/gcal-calendar-navigation-button.c b/src/gui/gcal-calendar-navigation-button.c index 788a3393..a5317a62 100644 --- a/src/gui/gcal-calendar-navigation-button.c +++ b/src/gui/gcal-calendar-navigation-button.c @@ -96,7 +96,8 @@ gcal_calendar_navigation_button_set_property (GObject *object, switch (prop_id) { case PROP_ACTIVE_DATE: - self->active_date = g_value_get_boxed (value); + gcal_clear_date_time (&self->active_date); + self->active_date = g_date_time_ref (g_value_get_boxed (value)); /* * Translators: %B is the month name and %Y is the year. * More formats can be found on the doc: