[dconf] gdbus: Work around threading deadlock in glib



commit 701d19d12d4e0599340c9bd1eb2b3e25a40d780b
Author: Colin Walters <walters verbum org>
Date:   Fri Nov 18 16:40:23 2016 -0500

    gdbus: Work around threading deadlock in glib
    
    See https://bugzilla.gnome.org/show_bug.cgi?id=674885
    for more details.  What dconf is doing right now provokes
    this more easily by involving *another* thread in the mix.

 gdbus/dconf-gdbus-thread.c |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/gdbus/dconf-gdbus-thread.c b/gdbus/dconf-gdbus-thread.c
index e397e3a..8ed28b5 100644
--- a/gdbus/dconf-gdbus-thread.c
+++ b/gdbus/dconf-gdbus-thread.c
@@ -94,6 +94,10 @@ dconf_gdbus_get_worker_context (void)
     {
       GMainContext *context;
 
+      /* Work around https://bugzilla.gnome.org/show_bug.cgi?id=674885 */
+      g_type_ensure (G_TYPE_DBUS_CONNECTION);
+      g_type_ensure (G_TYPE_DBUS_PROXY);
+
       context = g_main_context_new ();
       g_thread_new ("dconf worker", dconf_gdbus_worker_thread, context);
       g_once_init_leave (&worker_context, context);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]