[telepathy-gabble/master] Free GabbleCallStream's endpoints when disposing.
Mike Ruprecht
mike.ruprecht at collabora.co.uk
Tue Jan 5 17:40:11 PST 2010
---
src/call-stream.c | 9 +++++++++
1 files changed, 9 insertions(+), 0 deletions(-)
diff --git a/src/call-stream.c b/src/call-stream.c
index 6f9c474..2d3aa04 100644
--- a/src/call-stream.c
+++ b/src/call-stream.c
@@ -575,12 +575,21 @@ gabble_call_stream_dispose (GObject *object)
{
GabbleCallStream *self = GABBLE_CALL_STREAM (object);
GabbleCallStreamPrivate *priv = self->priv;
+ GList *l;
if (priv->dispose_has_run)
return;
priv->dispose_has_run = TRUE;
+ for (l = priv->endpoints; l != NULL; l = g_list_next (l))
+ {
+ g_object_unref (l->data);
+ }
+
+ g_list_free (priv->endpoints);
+ priv->endpoints = NULL;
+
if (priv->content != NULL)
g_object_unref (priv->content);
--
1.5.6.5
More information about the telepathy-commits
mailing list