]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
tmpfiles: fix wrong return value
authorYu Watanabe <watanabe.yu+github@gmail.com>
Sat, 24 Sep 2022 01:10:51 +0000 (10:10 +0900)
committerJan Janssen <medhefgo@web.de>
Sat, 24 Sep 2022 11:44:42 +0000 (13:44 +0200)
Follow-up for 27f6aa0b7112024c1236957abd909071b06869a8.

src/tmpfiles/tmpfiles.c

index 0031b6ee49d13f516c837acc2f236f227f6c6c16..705721ffbd38b8ac0ef6387a81f8b8940f728f40 100644 (file)
@@ -1802,7 +1802,7 @@ static int empty_directory(Item *i, const char *path, CreationMode creation) {
 
         r = chase_symlinks(path, arg_root, CHASE_SAFE|CHASE_WARN, NULL, &fd);
         if (r == -ENOLINK) /* Unsafe symlink: already covered by CHASE_WARN */
-                return fd;
+                return r;
         if (r == -ENOENT) {
                 /* Option "e" operates only on existing objects. Do not print errors about non-existent files
                  * or directories */