telepathy-salut: tubes-channel: fix 'might be used unset' warning from gcc 4.7

Jonny Lamb jonny at kemper.freedesktop.org
Tue Aug 28 06:30:37 PDT 2012


Module: telepathy-salut
Branch: master
Commit: 3360f5abbe98c28e6a2e6dfd5fe9553c80993e12
URL:    http://cgit.freedesktop.org/telepathy/telepathy-salut/commit/?id=3360f5abbe98c28e6a2e6dfd5fe9553c80993e12

Author: Jonny Lamb <jonny.lamb at collabora.co.uk>
Date:   Fri May 25 11:15:30 2012 +0100

tubes-channel: fix 'might be used unset' warning from gcc 4.7

Thanks for the heads up, GCC!

Signed-off-by: Jonny Lamb <jonny.lamb at collabora.co.uk>

---

 src/tubes-channel.c |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/src/tubes-channel.c b/src/tubes-channel.c
index 834c6ad..1d7a196 100644
--- a/src/tubes-channel.c
+++ b/src/tubes-channel.c
@@ -659,8 +659,10 @@ salut_tubes_channel_muc_message_received (SalutTubesChannel *self,
 
       stream_id = wocky_node_get_attribute (tube_node, "stream-id");
 
-      extract_tube_information (self, tube_node, NULL,
-          NULL, NULL, NULL, &tube_id);
+      if (!extract_tube_information (self, tube_node, NULL,
+              NULL, NULL, NULL, &tube_id))
+        continue;
+
       tube = g_hash_table_lookup (priv->tubes, GUINT_TO_POINTER (tube_id));
 
       if (tube == NULL)



More information about the telepathy-commits mailing list