[gedit/dbus] Move dbus_finalize to dbus_dispose
- From: Jesse van den Kieboom <jessevdk src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gedit/dbus] Move dbus_finalize to dbus_dispose
- Date: Sat, 15 May 2010 12:21:22 +0000 (UTC)
commit 7b8d7f3d637dca37fb36d175faef467fea022eeb
Author: Jesse van den Kieboom <jessevdk gnome org>
Date: Sat May 15 13:32:28 2010 +0200
Move dbus_finalize to dbus_dispose
gedit/gedit-dbus.c | 11 ++++++++---
1 files changed, 8 insertions(+), 3 deletions(-)
---
diff --git a/gedit/gedit-dbus.c b/gedit/gedit-dbus.c
index 983c6e0..bd7a16e 100644
--- a/gedit/gedit-dbus.c
+++ b/gedit/gedit-dbus.c
@@ -147,7 +147,7 @@ async_data_new (GeditDBus *dbus)
}
static void
-gedit_dbus_finalize (GObject *object)
+gedit_dbus_dispose (GObject *object)
{
GeditDBus *dbus = GEDIT_DBUS (object);
@@ -155,24 +155,29 @@ gedit_dbus_finalize (GObject *object)
{
g_cancellable_cancel (dbus->priv->stdin_cancellable);
g_object_unref (dbus->priv->stdin_cancellable);
+
+ dbus->priv->stdin_cancellable = NULL;
}
if (dbus->priv->stdin_fifo)
{
g_object_unref (dbus->priv->stdin_fifo);
+ dbus->priv->stdin_fifo = NULL;
}
if (dbus->priv->stdin_out_stream)
{
g_object_unref (dbus->priv->stdin_out_stream);
+ dbus->priv->stdin_out_stream = NULL;
}
if (dbus->priv->stdin_in_stream)
{
g_object_unref (dbus->priv->stdin_in_stream);
+ dbus->priv->stdin_in_stream = NULL;
}
- G_OBJECT_CLASS (gedit_dbus_parent_class)->finalize (object);
+ G_OBJECT_CLASS (gedit_dbus_parent_class)->dispose (object);
}
static void
@@ -180,7 +185,7 @@ gedit_dbus_class_init (GeditDBusClass *klass)
{
GObjectClass *object_class = G_OBJECT_CLASS (klass);
- object_class->finalize = gedit_dbus_finalize;
+ object_class->dispose = gedit_dbus_dispose;
g_type_class_add_private (object_class, sizeof(GeditDBusPrivate));
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]