]> err.no Git - systemd/commitdiff
acl: properly handle if devices are tagged as uaccess but do not have a device node
authorLennart Poettering <lennart@poettering.net>
Thu, 25 Aug 2011 14:50:49 +0000 (16:50 +0200)
committerLennart Poettering <lennart@poettering.net>
Thu, 25 Aug 2011 14:50:49 +0000 (16:50 +0200)
src/73-seat-late.rules.in
src/logind-acl.c

index e93a0e6da9f373f8ce8c0cbfb98af10fb4efa353..0847932d77577c09e75fff6dc942227c8ac503d4 100644 (file)
@@ -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"
index 7f9b0ca15ed91d65ca8777e7f7cb901340b548cc..7a06b501d45fbe420caae814abf40f54347e3011 100644 (file)
@@ -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);