summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorraveit65 <[email protected]>2013-10-03 21:08:49 +0200
committerStefano Karapetsas <[email protected]>2014-01-14 11:03:28 +0100
commitc7ffe41758c80f5c626edda4e61430be7c649542 (patch)
treed785f5a0dc7a8349064c6a630c9c41aa3035a086 /src
parent891196bc95d9be45c446206407383b65454b404f (diff)
downloadmate-screensaver-c7ffe41758c80f5c626edda4e61430be7c649542.tar.bz2
mate-screensaver-c7ffe41758c80f5c626edda4e61430be7c649542.tar.xz
Check for logind, not for systemd
Diffstat (limited to 'src')
-rw-r--r--src/gs-listener-dbus.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/gs-listener-dbus.c b/src/gs-listener-dbus.c
index e7b6c1d..dcccc33 100644
--- a/src/gs-listener-dbus.c
+++ b/src/gs-listener-dbus.c
@@ -25,6 +25,7 @@
#include <stdio.h>
#include <time.h>
#include <string.h>
+#include <unistd.h>
#include <glib/gi18n.h>
@@ -33,7 +34,6 @@
#include <dbus/dbus-glib-lowlevel.h>
#ifdef WITH_SYSTEMD
-#include <systemd/sd-daemon.h>
#include <systemd/sd-login.h>
#endif
@@ -2426,7 +2426,8 @@ gs_listener_init (GSListener *listener)
listener->priv = GS_LISTENER_GET_PRIVATE (listener);
#ifdef WITH_SYSTEMD
- listener->priv->have_systemd = sd_booted () > 0;
+ /* check if logind is running */
+ listener->priv->have_systemd = (access("/run/systemd/seats/", F_OK) >= 0);
#endif
gs_listener_dbus_init (listener);