diff options
author | Xavier Claessens <xclaesse@src.gnome.org> | 2008-04-20 05:04:22 +0800 |
---|---|---|
committer | Xavier Claessens <xclaesse@src.gnome.org> | 2008-04-20 05:04:22 +0800 |
commit | 14ed90780c03a6d14601cd898d048b70d4a941a9 (patch) | |
tree | 82602ba4234f541a71d2d6b39982e4c2c9bbfb77 | |
parent | f5f136b53e8f31f2eaf373240fa46fb57f526112 (diff) | |
download | gsoc2013-empathy-14ed90780c03a6d14601cd898d048b70d4a941a9.tar gsoc2013-empathy-14ed90780c03a6d14601cd898d048b70d4a941a9.tar.gz gsoc2013-empathy-14ed90780c03a6d14601cd898d048b70d4a941a9.tar.bz2 gsoc2013-empathy-14ed90780c03a6d14601cd898d048b70d4a941a9.tar.lz gsoc2013-empathy-14ed90780c03a6d14601cd898d048b70d4a941a9.tar.xz gsoc2013-empathy-14ed90780c03a6d14601cd898d048b70d4a941a9.tar.zst gsoc2013-empathy-14ed90780c03a6d14601cd898d048b70d4a941a9.zip |
Quit the tubes chandler when there is no more handled channels
svn path=/trunk/; revision=983
-rw-r--r-- | src/empathy-tubes-chandler.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/empathy-tubes-chandler.c b/src/empathy-tubes-chandler.c index 09f9555d6..f23281875 100644 --- a/src/empathy-tubes-chandler.c +++ b/src/empathy-tubes-chandler.c @@ -33,6 +33,9 @@ #define DEBUG_DOMAIN "TubesChandler" +static GMainLoop *loop = NULL; + + static void async_cb (TpProxy *channel, const GError *error, @@ -166,6 +169,8 @@ channel_invalidated_cb (TpProxy *proxy, { empathy_debug (DEBUG_DOMAIN, "Channel invalidated: %p", proxy); g_hash_table_remove (channels, proxy); + if (g_hash_table_size (channels) == 0) + g_main_loop_quit (loop); } static void @@ -245,7 +250,6 @@ int main (int argc, char *argv[]) { EmpathyChandler *chandler; - GMainLoop *loop; GHashTable *channels; g_type_init (); |