summaryrefslogtreecommitdiffstats
path: root/src/daemon
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2008-07-31 01:25:33 +0200
committerLennart Poettering <lennart@poettering.net>2008-07-31 01:25:33 +0200
commit026a6bdd0ecdc68288b2167aed6dfd4e6f407edb (patch)
treed067c092fafe8df184670fc5e6cf5489c29338ef /src/daemon
parent0b428e7cb1efdd7330b89a9855f08c45bfa98307 (diff)
Work around D-Bus bug that involves dbus_shutdown() to call exit() when it shouldn't. Patch from Coling Guthrie
Diffstat (limited to 'src/daemon')
-rw-r--r--src/daemon/polkit.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/daemon/polkit.c b/src/daemon/polkit.c
index 256e3199..dc0eee78 100644
--- a/src/daemon/polkit.c
+++ b/src/daemon/polkit.c
@@ -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;