[next] telepathy-glib: media-observer: ref the channel before connecting the signal
Simon McVittie
smcv at kemper.freedesktop.org
Wed Sep 17 05:22:52 PDT 2014
Module: telepathy-glib
Branch: next
Commit: 122f428cfe103a36ffd72a54178b73ace42855c4
URL: http://cgit.freedesktop.org/telepathy/telepathy-glib/commit/?id=122f428cfe103a36ffd72a54178b73ace42855c4
Author: Guillaume Desmottes <guillaume.desmottes at collabora.co.uk>
Date: Thu May 29 15:09:35 2014 +0200
media-observer: ref the channel before connecting the signal
g_object_ref() returns a gpointer so Tartan can't check if the signal we are
connecting to actually exists.
---
examples/client/media-observer.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/examples/client/media-observer.c b/examples/client/media-observer.c
index 0fe95e5..5e43005 100644
--- a/examples/client/media-observer.c
+++ b/examples/client/media-observer.c
@@ -51,7 +51,9 @@ observe_channel_cb (TpSimpleObserver *self,
requested? "to": "from",
tp_channel_get_identifier (channel));
- g_signal_connect (g_object_ref (channel), "invalidated",
+ g_object_ref (channel);
+
+ g_signal_connect (channel, "invalidated",
G_CALLBACK (chan_invalidated_cb), NULL);
tp_observe_channel_context_accept (context);
More information about the telepathy-commits
mailing list