[empathy] ft-factory: don't leak the handler
- From: Guillaume Desmottes <gdesmott src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [empathy] ft-factory: don't leak the handler
- Date: Wed, 16 Feb 2011 11:42:12 +0000 (UTC)
commit 6ea60bb165253f1355d9fbfa1a5a010fb79c2c06
Author: Guillaume Desmottes <guillaume desmottes collabora co uk>
Date: Thu Dec 16 10:48:52 2010 +0100
ft-factory: don't leak the handler
libempathy/empathy-ft-factory.c | 12 ++++++++++++
1 files changed, 12 insertions(+), 0 deletions(-)
---
diff --git a/libempathy/empathy-ft-factory.c b/libempathy/empathy-ft-factory.c
index 3443112..3984747 100644
--- a/libempathy/empathy-ft-factory.c
+++ b/libempathy/empathy-ft-factory.c
@@ -89,6 +89,17 @@ do_constructor (GType type,
}
static void
+empathy_ft_factory_dispose (GObject *object)
+{
+ EmpathyFTFactory *self = (EmpathyFTFactory *) object;
+ EmpathyFTFactoryPriv *priv = GET_PRIV (self);
+
+ tp_clear_object (&priv->handler);
+
+ (G_OBJECT_CLASS (empathy_ft_factory_parent_class)->dispose) (object);
+}
+
+static void
empathy_ft_factory_class_init (EmpathyFTFactoryClass *klass)
{
GObjectClass *object_class = G_OBJECT_CLASS (klass);
@@ -96,6 +107,7 @@ empathy_ft_factory_class_init (EmpathyFTFactoryClass *klass)
g_type_class_add_private (klass, sizeof (EmpathyFTFactoryPriv));
object_class->constructor = do_constructor;
+ object_class->dispose = empathy_ft_factory_dispose;
/**
* EmpathyFTFactory::new-ft-handler
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]