diff options
author | Jan Alexander Steffens (heftig) <jan.steffens@gmail.com> | 2015-06-21 05:59:34 +0200 |
---|---|---|
committer | Daniel Mack <daniel@zonque.org> | 2015-06-21 11:24:59 +0200 |
commit | c5d452bb228e9f97ebc96be98a957c0b7b8072eb (patch) | |
tree | 6c0a779dc4b300b1ed2cf673ef3922ed43b85e92 | |
parent | 94c5528dc2b2bd4997729637b9f422dcd04e23a1 (diff) |
pam_systemd: Properly check kdbus availability
This properly avoids setting DBUS_SESSION_BUS_ADDRESS if kdbus
is loaded (or built into the kernel) but not wanted.
-rw-r--r-- | src/login/pam_systemd.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/login/pam_systemd.c b/src/login/pam_systemd.c index 0ebdfdf19e..dd192b90ce 100644 --- a/src/login/pam_systemd.c +++ b/src/login/pam_systemd.c @@ -181,7 +181,7 @@ static int export_legacy_dbus_address( int r; /* skip export if kdbus is not active */ - if (access("/sys/fs/kdbus", F_OK) < 0) + if (!is_kdbus_available()) return PAM_SUCCESS; if (asprintf(&s, KERNEL_USER_BUS_ADDRESS_FMT ";" UNIX_USER_BUS_ADDRESS_FMT, uid, runtime) < 0) { |