From d2d4b038999d65826a2048a1a7829f9d5e762978 Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Thu, 25 Aug 2011 16:50:49 +0200 Subject: acl: properly handle if devices are tagged as uaccess but do not have a device node --- src/73-seat-late.rules.in | 2 +- src/logind-acl.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/73-seat-late.rules.in b/src/73-seat-late.rules.in index e93a0e6da9..0847932d77 100644 --- a/src/73-seat-late.rules.in +++ b/src/73-seat-late.rules.in @@ -12,6 +12,6 @@ ENV{ID_SEAT}=="", IMPORT{parent}="ID_SEAT" ENV{ID_SEAT}!="", TAG+="$env{ID_SEAT}" -TAG=="uaccess", RUN+="@rootlibexecdir@/systemd-uaccess $env{DEVNAME} $env{ID_SEAT}" +TAG=="uaccess", ENV{MAJOR}!="", RUN+="@rootlibexecdir@/systemd-uaccess $env{DEVNAME} $env{ID_SEAT}" LABEL="seat_late_end" diff --git a/src/logind-acl.c b/src/logind-acl.c index 7f9b0ca15e..7a06b501d4 100644 --- a/src/logind-acl.c +++ b/src/logind-acl.c @@ -265,9 +265,9 @@ int devnode_acl_all(struct udev *udev, node = udev_device_get_devnode(d); if (!node) { + /* In case people mistag devices with nodes, we need to ignore this */ udev_device_unref(d); - r = -ENOMEM; - goto finish; + continue; } log_debug("Fixing up %s for seat %s...", node, sn); -- cgit v1.2.3-54-g00ecf