[telepathy-glib/master] TpProxy: don't release TpDBusDaemon until dispose
Simon McVittie
simon.mcvittie at collabora.co.uk
Wed May 27 03:45:22 PDT 2009
It's safe to keep an invalidated TpDBusDaemon around, since it's a TpProxy
itself.
---
telepathy-glib/proxy.c | 12 ++++++------
1 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/telepathy-glib/proxy.c b/telepathy-glib/proxy.c
index 7a7e3cb..163bc69 100644
--- a/telepathy-glib/proxy.c
+++ b/telepathy-glib/proxy.c
@@ -412,12 +412,6 @@ tp_proxy_emit_invalidated (gpointer p)
* to the proxies */
tp_proxy_lose_interfaces (self);
- if (self->dbus_daemon != NULL)
- {
- g_object_unref (self->dbus_daemon);
- self->dbus_daemon = NULL;
- }
-
if (self->dbus_connection != NULL)
{
dbus_g_connection_unref (self->dbus_connection);
@@ -843,6 +837,12 @@ tp_proxy_dispose (GObject *object)
tp_proxy_invalidate (self, &e);
+ if (self->dbus_daemon != NULL)
+ {
+ g_object_unref (self->dbus_daemon);
+ self->dbus_daemon = NULL;
+ }
+
G_OBJECT_CLASS (tp_proxy_parent_class)->dispose (object);
}
--
1.5.6.5
More information about the telepathy-commits
mailing list