]> code.delx.au - pulseaudio/commitdiff
core-util: call dbus_connection_set_exit_on_disconnect() on shared busses to make...
authorLennart Poettering <lennart@poettering.net>
Wed, 2 Sep 2009 02:03:18 +0000 (04:03 +0200)
committerLennart Poettering <lennart@poettering.net>
Wed, 2 Sep 2009 02:03:18 +0000 (04:03 +0200)
src/pulsecore/core-util.c

index 9034dc32bf2d57c166f87b271360ae7c0be4f509..eeb81a604283c6819e75d515726b9402cc22285f 100644 (file)
@@ -612,6 +612,11 @@ static int set_scheduler(int rtprio) {
         return -1;
     }
 
+    /* We need to disable exit on disconnect because otherwise
+     * dbus_shutdown will kill us. See
+     * https://bugs.freedesktop.org/show_bug.cgi?id=16924 */
+    dbus_connection_set_exit_on_disconnect(bus, FALSE);
+
     r = rtkit_make_realtime(bus, 0, rtprio);
     dbus_connection_unref(bus);
 
@@ -680,6 +685,11 @@ static int set_nice(int nice_level) {
         return -1;
     }
 
+    /* We need to disable exit on disconnect because otherwise
+     * dbus_shutdown will kill us. See
+     * https://bugs.freedesktop.org/show_bug.cgi?id=16924 */
+    dbus_connection_set_exit_on_disconnect(bus, FALSE);
+
     r = rtkit_make_high_priority(bus, 0, nice_level);
     dbus_connection_unref(bus);