display: Fix crash when the screen setup changes
after the Display panel has been closed. https://bugzilla.gnome.org/show_bug.cgi?id=670570
This commit is contained in:
parent
3844923a4b
commit
49f9de6182
1 changed files with 2 additions and 0 deletions
|
@ -117,6 +117,7 @@ static char *make_resolution_string (int width, int height);
|
||||||
static GObject *cc_display_panel_constructor (GType gtype,
|
static GObject *cc_display_panel_constructor (GType gtype,
|
||||||
guint n_properties,
|
guint n_properties,
|
||||||
GObjectConstructParam *properties);
|
GObjectConstructParam *properties);
|
||||||
|
static void on_screen_changed (GnomeRRScreen *scr, gpointer data);
|
||||||
|
|
||||||
static void
|
static void
|
||||||
cc_display_panel_get_property (GObject *object,
|
cc_display_panel_get_property (GObject *object,
|
||||||
|
@ -159,6 +160,7 @@ cc_display_panel_finalize (GObject *object)
|
||||||
|
|
||||||
self = CC_DISPLAY_PANEL (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->screen);
|
||||||
g_object_unref (self->priv->builder);
|
g_object_unref (self->priv->builder);
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue