diff options
author | Sebastien Bacher <seb128@ubuntu.com> | 2012-03-09 13:49:52 +0100 |
---|---|---|
committer | Sebastien Bacher <seb128@ubuntu.com> | 2012-03-09 13:49:52 +0100 |
commit | ad979590948f582a8b521432a49528103698f596 (patch) | |
tree | 0f0f3d2e05101e021f52324147457f65554c2932 /src/datetime-interface.c | |
parent | 39bc08ed8c8c3d1be351c2642c8e2eb572a3061c (diff) | |
parent | fa7f146fafa83e8e612365a5f74ba06ff438d36a (diff) | |
download | ayatana-indicator-datetime-ad979590948f582a8b521432a49528103698f596.tar.gz ayatana-indicator-datetime-ad979590948f582a8b521432a49528103698f596.tar.bz2 ayatana-indicator-datetime-ad979590948f582a8b521432a49528103698f596.zip |
releasing version 0.3.91-0ubuntu1
Diffstat (limited to 'src/datetime-interface.c')
-rw-r--r-- | src/datetime-interface.c | 13 |
1 files changed, 3 insertions, 10 deletions
diff --git a/src/datetime-interface.c b/src/datetime-interface.c index 5939061..e67be85 100644 --- a/src/datetime-interface.c +++ b/src/datetime-interface.c @@ -124,10 +124,7 @@ bus_get_cb (GObject * object, GAsyncResult * res, gpointer user_data) g_warn_if_fail(priv->bus == NULL); priv->bus = connection; - if (priv->bus_cancel != NULL) { - g_object_unref(priv->bus_cancel); - priv->bus_cancel = NULL; - } + g_clear_object (&priv->bus_cancel); /* Now register our object on our new connection */ priv->dbus_registration = g_dbus_connection_register_object(priv->bus, @@ -158,15 +155,11 @@ datetime_interface_dispose (GObject *object) priv->dbus_registration = 0; } - if (priv->bus != NULL) { - g_object_unref(priv->bus); - priv->bus = NULL; - } + g_clear_object (&priv->bus); if (priv->bus_cancel != NULL) { g_cancellable_cancel(priv->bus_cancel); - g_object_unref(priv->bus_cancel); - priv->bus_cancel = NULL; + g_clear_object (&priv->bus_cancel); } G_OBJECT_CLASS (datetime_interface_parent_class)->dispose (object); |