[telepathy-glib/master] Stop channel introspection when invalidated.

Will Thompson will.thompson at collabora.co.uk
Fri May 15 08:21:36 PDT 2009


This avoids a big chain of synchronous error callbacks to method calls
when a channel is invalidated during introspection.
---
 telepathy-glib/channel.c |    9 ++++++++-
 1 files changed, 8 insertions(+), 1 deletions(-)

diff --git a/telepathy-glib/channel.c b/telepathy-glib/channel.c
index b8ce376..72f333a 100644
--- a/telepathy-glib/channel.c
+++ b/telepathy-glib/channel.c
@@ -523,7 +523,14 @@ _tp_channel_continue_introspection (TpChannel *self)
 
   g_assert (self->priv->introspect_needed != NULL);
 
-  if (g_queue_peek_head (self->priv->introspect_needed) == NULL)
+  if (tp_proxy_get_invalidated (self))
+    {
+      DEBUG ("invalidated; giving up");
+
+      g_queue_free (self->priv->introspect_needed);
+      self->priv->introspect_needed = NULL;
+    }
+  else if (g_queue_peek_head (self->priv->introspect_needed) == NULL)
     {
       g_queue_free (self->priv->introspect_needed);
       self->priv->introspect_needed = NULL;
-- 
1.5.6.5




More information about the telepathy-commits mailing list