summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/login/pam_systemd.c2
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) {