[Telepathy-commits] [telepathy-glib/master] Amend a comment to indicate that no, we can't combine unrefs via g_idle_add

Simon McVittie simon.mcvittie at collabora.co.uk
Tue Oct 7 08:43:18 PDT 2008


---
 telepathy-glib/connection-handles.c |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/telepathy-glib/connection-handles.c b/telepathy-glib/connection-handles.c
index 1527ac5..f3c0671 100644
--- a/telepathy-glib/connection-handles.c
+++ b/telepathy-glib/connection-handles.c
@@ -285,8 +285,10 @@ tp_connection_unref_handles (TpConnection *self,
         }
     }
 
-  /* fire off the unref call asynchronously, ignore error if any.
-   * FIXME: perhaps this should be done idly, so we can combine unrefs? */
+  /* Fire off the unref call asynchronously, ignore error if any.
+   * This can't be done idly (so we can combine unrefs) without additional
+   * checks, since that would introduce a race between the idle handler
+   * running, and someone else holding the handles again. */
   if (unref->len > 0)
     {
       DEBUG ("releasing %u handles", unref->len);
-- 
1.5.6.5




More information about the Telepathy-commits mailing list