[gnome-calendar/mcatanzaro/rbz-1672235: 2/2] Fix crash in source_color_changed()



commit 1b30b359fd2956d76c371d7ed6a58e6275a9b057
Author: Michael Catanzaro <mcatanzaro igalia com>
Date:   Wed Jul 3 16:48:51 2019 -0500

    Fix crash in source_color_changed()
    
    And opportunistically use g_signal_connect_object() when connecting to
    the source object as well, because it's probably needed.
    
    It looks like this is already fixed in a different way for master, so
    this is only for gnome-3-32. Fixes:
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1672235

 src/gcal-source-dialog.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/src/gcal-source-dialog.c b/src/gcal-source-dialog.c
index b1aa1d99..0848e5cc 100644
--- a/src/gcal-source-dialog.c
+++ b/src/gcal-source-dialog.c
@@ -620,11 +620,11 @@ make_row_from_source (GcalSourceDialog *dialog,
   top_label = GTK_WIDGET (gtk_builder_get_object (builder, "title"));
   gtk_label_set_label (GTK_LABEL (top_label), e_source_get_display_name (source));
   g_object_bind_property (source, "display-name", top_label, "label", G_BINDING_DEFAULT | 
G_BINDING_SYNC_CREATE);
-  g_signal_connect (source, "notify::display-name", G_CALLBACK (invalidate_calendar_listbox_sort),
-                    dialog->calendars_listbox);
+  g_signal_connect_object (source, "notify::display-name", G_CALLBACK (invalidate_calendar_listbox_sort),
+                           dialog->calendars_listbox, 0);
 
   extension = E_SOURCE_SELECTABLE (e_source_get_extension (source, E_SOURCE_EXTENSION_CALENDAR));
-  g_signal_connect (extension, "notify::color", G_CALLBACK (source_color_changed), icon);
+  g_signal_connect_object (extension, "notify::color", G_CALLBACK (source_color_changed), icon, 0);
 
   /* parent source name label */
   bottom_label = GTK_WIDGET (gtk_builder_get_object (builder, "subtitle"));


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]