gtestdbus: Don't destroy GSource twice

https://bugzilla.gnome.org/show_bug.cgi?id=711806
This commit is contained in:
Stef Walter 2013-11-09 20:17:49 +01:00 committed by Matthias Clasen
parent 047d9ce6f2
commit 797959f05a

View File

@ -93,13 +93,15 @@ _g_object_unref_and_wait_weak_notify (gpointer object)
g_main_loop_run (data.loop); g_main_loop_run (data.loop);
g_source_remove (timeout_id);
if (data.timed_out) if (data.timed_out)
{ {
g_warning ("Weak notify timeout, object ref_count=%d\n", g_warning ("Weak notify timeout, object ref_count=%d\n",
G_OBJECT (object)->ref_count); G_OBJECT (object)->ref_count);
} }
else
{
g_source_remove (timeout_id);
}
g_main_loop_unref (data.loop); g_main_loop_unref (data.loop);
return data.timed_out; return data.timed_out;