aboutsummaryrefslogtreecommitdiffstats
path: root/libempathy/empathy-server-tls-handler.c
diff options
context:
space:
mode:
authorCosimo Cecchi <cosimoc@gnome.org>2010-08-12 01:01:01 +0800
committerCosimo Cecchi <cosimoc@gnome.org>2010-08-13 22:22:23 +0800
commit5c313ddb2557218b7ccd4b3dd13dc1aad3834506 (patch)
treee2fbf3eb4fa355c6f98dff76316e5caddce32f41 /libempathy/empathy-server-tls-handler.c
parent50f265ad2feffc9826a0c3a77782673fc39fca0e (diff)
downloadgsoc2013-empathy-5c313ddb2557218b7ccd4b3dd13dc1aad3834506.tar
gsoc2013-empathy-5c313ddb2557218b7ccd4b3dd13dc1aad3834506.tar.gz
gsoc2013-empathy-5c313ddb2557218b7ccd4b3dd13dc1aad3834506.tar.bz2
gsoc2013-empathy-5c313ddb2557218b7ccd4b3dd13dc1aad3834506.tar.lz
gsoc2013-empathy-5c313ddb2557218b7ccd4b3dd13dc1aad3834506.tar.xz
gsoc2013-empathy-5c313ddb2557218b7ccd4b3dd13dc1aad3834506.tar.zst
gsoc2013-empathy-5c313ddb2557218b7ccd4b3dd13dc1aad3834506.zip
Make sure to release all the references
Diffstat (limited to 'libempathy/empathy-server-tls-handler.c')
-rw-r--r--libempathy/empathy-server-tls-handler.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/libempathy/empathy-server-tls-handler.c b/libempathy/empathy-server-tls-handler.c
index feabdfbcd..10a2daf20 100644
--- a/libempathy/empathy-server-tls-handler.c
+++ b/libempathy/empathy-server-tls-handler.c
@@ -20,6 +20,8 @@
#include "empathy-server-tls-handler.h"
+#include <telepathy-glib/util.h>
+
#define DEBUG_FLAG EMPATHY_DEBUG_TLS
#include "empathy-debug.h"
#include "empathy-tls-certificate.h"
@@ -74,6 +76,7 @@ tls_certificate_constructed_cb (GObject *source,
}
g_simple_async_result_complete_in_idle (priv->async_init_res);
+ g_object_unref (priv->async_init_res);
}
static void
@@ -90,6 +93,7 @@ server_tls_channel_got_all_cb (TpProxy *proxy,
{
g_simple_async_result_set_from_error (priv->async_init_res, error);
g_simple_async_result_complete_in_idle (priv->async_init_res);
+ g_object_unref (priv->async_init_res);
}
else
{
@@ -163,9 +167,9 @@ empathy_server_tls_handler_finalize (GObject *object)
EmpathyServerTLSHandlerPriv *priv = GET_PRIV (object);
DEBUG ("%p", object);
-
- if (priv->channel != NULL)
- g_object_unref (priv->channel);
+
+ tp_clear_object (&priv->channel);
+ tp_clear_object (&priv->certificate);
G_OBJECT_CLASS (empathy_server_tls_handler_parent_class)->finalize (object);
}