Commit 7b575f61 authored by Max Kellermann's avatar Max Kellermann

Main: notify systemd when MPD is ready

parent 400e3ea6
......@@ -106,6 +106,10 @@
#include <glib.h>
#endif
#ifdef ENABLE_SYSTEMD_DAEMON
#include <systemd/sd-daemon.h>
#endif
#include <stdlib.h>
#ifdef HAVE_LOCALE_H
......@@ -662,6 +666,10 @@ static int mpd_main_after_fork(struct options options)
a huge value to allow the kernel to reduce CPU wakeups */
SetThreadTimerSlackMS(100);
#ifdef ENABLE_SYSTEMD_DAEMON
sd_notify(0, "READY=1");
#endif
/* run the main loop */
instance->event_loop->Run();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment