From: Alexander Larsson Date: Fri, 15 May 2009 08:05:55 +0000 (+0200) Subject: Fix deadlock in threaded resolver X-Git-Url: http://git.openbox.org/?a=commitdiff_plain;h=a258ec3b5bf0a0b2ab1cb1dce8ce715c3895bdaa;p=dana%2Fcg-glib.git Fix deadlock in threaded resolver When you're using the threaded resolver and using a sync call without a cancellable the resolve_sync forgot to unlock the initial req->mutex lock, leading to a deadlock when unrefing the request. --- diff --git a/gio/gthreadedresolver.c b/gio/gthreadedresolver.c index 6732612e..c259b572 100644 --- a/gio/gthreadedresolver.c +++ b/gio/gthreadedresolver.c @@ -319,6 +319,7 @@ resolve_sync (GThreadedResolver *gtr, if (!req->cancellable || !gtr->thread_pool) { req->resolve_func (req, error); + g_mutex_unlock (req->mutex); return; }