[gnome-control-center/gnome-3-2] display: Fix crash when the screen setup changes



commit 6c47e55c87dfd84dc9da7af36d826630320a94dd
Author: Michael Terry <michael terry canonical com>
Date:   Thu Mar 1 16:00:09 2012 +0000

    display: Fix crash when the screen setup changes
    
    after the Display panel has been closed.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=670570

 panels/display/cc-display-panel.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)
---
diff --git a/panels/display/cc-display-panel.c b/panels/display/cc-display-panel.c
index ac75511..65f26c1 100644
--- a/panels/display/cc-display-panel.c
+++ b/panels/display/cc-display-panel.c
@@ -121,6 +121,7 @@ static char *make_resolution_string (int width, int height);
 static GObject *cc_display_panel_constructor (GType                  gtype,
 					      guint                  n_properties,
 					      GObjectConstructParam *properties);
+static void on_screen_changed (GnomeRRScreen *scr, gpointer data);
 
 static void
 cc_display_panel_get_property (GObject    *object,
@@ -163,6 +164,7 @@ cc_display_panel_finalize (GObject *object)
 
   self = CC_DISPLAY_PANEL (object);
 
+  g_signal_handlers_disconnect_by_func (self->priv->screen, on_screen_changed, self);
   g_object_unref (self->priv->screen);
   g_object_unref (self->priv->builder);
 



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