Avoid race when using GConf and DBus with threads (bgo#692374)
GConf causes us to make indirect calls to libdbus from multiple threads,
resulting in crashes if threads are not initialized explictly. As a
workaround, we initialize dbus-glib for multithreading.
This fixes adds an optional build-time dependency on dbus-glib, and will
only be enabled if that dependency is satisfied.
Some distros have addressed this issue by patching the underlying
llibraries (gconf or gconf-sharp), so they don't have to enable that
fix. But it should not conflict with those patches, as
dbus_g_thread_init can be called multiple time, contrary to what the
API documentation says.
Signed-off-by: Bertrand Lorentz <bertrand.lorentz@gmail.com>
parent
ac6c2f49
Please register or sign in to comment