summaryrefslogtreecommitdiffstats
path: root/src/pulsecore/cli-command.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/pulsecore/cli-command.c')
-rw-r--r--src/pulsecore/cli-command.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/pulsecore/cli-command.c b/src/pulsecore/cli-command.c
index 8e8f5f28..a80933fa 100644
--- a/src/pulsecore/cli-command.c
+++ b/src/pulsecore/cli-command.c
@@ -188,7 +188,9 @@ static int pa_cli_command_exit(pa_core *c, pa_tokenizer *t, pa_strbuf *buf, pa_b
pa_assert(buf);
pa_assert(fail);
- c->mainloop->quit(c->mainloop, 0);
+ if (pa_core_exit(c, FALSE, 0) < 0)
+ pa_strbuf_puts(buf, "Not allowed to terminate daemon.\n");
+
return 0;
}