aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>2012-04-16 15:39:42 +0800
committerGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>2012-05-10 15:48:06 +0800
commit77e0eed9fb363177cbd54a2659105c4e6a288c8d (patch)
treef1eeba27773cdb1a3e1e23db72af997952fe271d
parent6e1feb9fafe3f46f8a0a5c0ffa11dea0a4a07d15 (diff)
downloadgsoc2013-empathy-77e0eed9fb363177cbd54a2659105c4e6a288c8d.tar
gsoc2013-empathy-77e0eed9fb363177cbd54a2659105c4e6a288c8d.tar.gz
gsoc2013-empathy-77e0eed9fb363177cbd54a2659105c4e6a288c8d.tar.bz2
gsoc2013-empathy-77e0eed9fb363177cbd54a2659105c4e6a288c8d.tar.lz
gsoc2013-empathy-77e0eed9fb363177cbd54a2659105c4e6a288c8d.tar.xz
gsoc2013-empathy-77e0eed9fb363177cbd54a2659105c4e6a288c8d.tar.zst
gsoc2013-empathy-77e0eed9fb363177cbd54a2659105c4e6a288c8d.zip
debug_window_dispose: use g_clear_object()
https://bugzilla.gnome.org/show_bug.cgi?id=674182
-rw-r--r--src/empathy-debug-window.c24
1 files changed, 4 insertions, 20 deletions
diff --git a/src/empathy-debug-window.c b/src/empathy-debug-window.c
index 8110a14f3..e00d59afc 100644
--- a/src/empathy-debug-window.c
+++ b/src/empathy-debug-window.c
@@ -2143,8 +2143,6 @@ empathy_debug_window_init (EmpathyDebugWindow *empathy_debug_window)
EMPATHY_TYPE_DEBUG_WINDOW, EmpathyDebugWindowPriv);
empathy_debug_window->priv = priv;
-
- priv->dispose_run = FALSE;
}
static void
@@ -2191,27 +2189,13 @@ debug_window_dispose (GObject *object)
EmpathyDebugWindow *selector = EMPATHY_DEBUG_WINDOW (object);
EmpathyDebugWindowPriv *priv = GET_PRIV (selector);
- if (priv->dispose_run)
- return;
-
- priv->dispose_run = TRUE;
-
if (priv->name_owner_changed_signal != NULL)
tp_proxy_signal_connection_disconnect (priv->name_owner_changed_signal);
- if (priv->service_store != NULL)
- g_object_unref (priv->service_store);
-
- if (priv->dbus != NULL)
- g_object_unref (priv->dbus);
-
- if (priv->am != NULL)
- {
- g_object_unref (priv->am);
- priv->am = NULL;
- }
-
- tp_clear_object (&priv->all_active_buffer);
+ g_clear_object (&priv->service_store);
+ g_clear_object (&priv->dbus);
+ g_clear_object (&priv->am);
+ g_clear_object (&priv->all_active_buffer);
(G_OBJECT_CLASS (empathy_debug_window_parent_class)->dispose) (object);
}