]> code.delx.au - pulseaudio/commitdiff
Work around D-Bus bug that involves dbus_shutdown() to call exit() when it shouldn...
authorLennart Poettering <lennart@poettering.net>
Wed, 30 Jul 2008 23:25:33 +0000 (01:25 +0200)
committerLennart Poettering <lennart@poettering.net>
Wed, 30 Jul 2008 23:25:33 +0000 (01:25 +0200)
src/daemon/polkit.c

index 256e319988f8a55b926cc007b81a4f5f286d17a8..dc0eee78ed7d48e565936e71f5fb3296e8a13cba 100644 (file)
@@ -54,6 +54,11 @@ int pa_polkit_check(const char *action_id) {
         goto finish;
     }
 
+    /* There seems to be a bug in D-Bus that causes dbus_shutdown() to
+     * call exit() when a connection without this flag disabled was
+     * created during runtime.*/
+    dbus_connection_set_exit_on_disconnect(bus, FALSE);
+
     if (!(caller = polkit_caller_new_from_pid(bus, getpid(), &dbus_error))) {
         pa_log_error("Cannot get caller from PID: %s", dbus_error.message);
         goto finish;