summaryrefslogtreecommitdiff
path: root/gui/libgdm
diff options
context:
space:
mode:
authorMartin Pitt <martinpitt@gnome.org>2013-03-21 11:47:56 +0100
committerMartin Pitt <martinpitt@gnome.org>2013-03-29 11:04:18 +0100
commit064ebd55bb838a4225e8cb525717e315c29d4d8b (patch)
tree16e9d8f8c0ad56ca6eb3157fc173e6ef3d3eef96 /gui/libgdm
parent1fe1e565300eb9472cfc4348e4bceef5ef25512a (diff)
downloadgdm-064ebd55bb838a4225e8cb525717e315c29d4d8b.tar.gz
Fix checks for logind
It is possible to build systemd without logind or run logind without systemd init, in both cases testing for systemd init is wrong. Check for /run/systemd/seats in the parts which talk to logind instead, as recommended by systemd upstream. For details, see: <https://mail.gnome.org/archives/desktop-devel-list/2013-March/msg00092.html> https://bugzilla.gnome.org/show_bug.cgi?id=696266
Diffstat (limited to 'gui/libgdm')
-rw-r--r--gui/libgdm/gdm-user-switching.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gui/libgdm/gdm-user-switching.c b/gui/libgdm/gdm-user-switching.c
index c4342f27..ebfef1c3 100644
--- a/gui/libgdm/gdm-user-switching.c
+++ b/gui/libgdm/gdm-user-switching.c
@@ -32,10 +32,10 @@
#include <gio/gio.h>
#ifdef WITH_SYSTEMD
-#include <systemd/sd-daemon.h>
#include <systemd/sd-login.h>
#endif
+#include "common/gdm-common.h"
#include "gdm-user-switching.h"
#include "gdm-client.h"
@@ -578,7 +578,7 @@ gdm_goto_login_session_sync (GCancellable *cancellable,
return FALSE;
#ifdef WITH_SYSTEMD
- if (sd_booted () > 0) {
+ if (LOGIND_RUNNING()) {
retval = goto_login_session_for_systemd (connection,
cancellable,
error);