From 487093320532dc68dd89e4878850a5d55d2a6cbb Mon Sep 17 00:00:00 2001 From: JP Rosevear Date: Fri, 16 May 2003 14:57:15 +0000 Subject: unref the client and the ui component 2003-05-15 JP Rosevear * gui/dialogs/comp-editor.c (comp_editor_finalize): unref the client and the ui component svn path=/trunk/; revision=21211 --- calendar/gui/dialogs/comp-editor.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'calendar/gui/dialogs') diff --git a/calendar/gui/dialogs/comp-editor.c b/calendar/gui/dialogs/comp-editor.c index 70ad1abe8f..7a462c9a1f 100644 --- a/calendar/gui/dialogs/comp-editor.c +++ b/calendar/gui/dialogs/comp-editor.c @@ -262,8 +262,12 @@ comp_editor_finalize (GObject *object) editor = COMP_EDITOR (object); priv = editor->priv; - g_signal_handlers_disconnect_matched (priv->client, G_SIGNAL_MATCH_DATA, 0, 0, NULL, NULL, editor); - + if (priv->client) { + g_signal_handlers_disconnect_matched (priv->client, G_SIGNAL_MATCH_DATA, 0, 0, NULL, NULL, editor); + g_object_unref (priv->client); + priv->client = NULL; + } + /* We want to destroy the pages after the widgets get destroyed, since they have lots of signal handlers connected to the widgets with the pages as the data. */ @@ -275,6 +279,8 @@ comp_editor_finalize (GObject *object) priv->comp = NULL; } + bonobo_object_unref (priv->uic); + g_free (priv); editor->priv = NULL; -- cgit v1.2.3