]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
udev: do not try to remove /dev
authorYu Watanabe <watanabe.yu+github@gmail.com>
Wed, 2 Jun 2021 14:52:46 +0000 (23:52 +0900)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Fri, 4 Jun 2021 06:51:39 +0000 (15:51 +0900)
src/udev/udev-node.c

index 5e556926f98286c1b1cb0b0ed11c5fe2778dddb7..14a5e8126f4cf14bde4bb3590caa07af6301cfe5 100644 (file)
@@ -308,7 +308,7 @@ static int link_update(sd_device *dev, const char *slink_in, bool add) {
                 if (r == -ENOENT) {
                         log_device_debug(dev, "No reference left, removing '%s'", slink);
                         if (unlink(slink) == 0)
-                                (void) rmdir_parents(slink, "/");
+                                (void) rmdir_parents(slink, "/dev");
 
                         break;
                 } else if (r < 0)