]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
tmpfiles: simplify mountpoint detection 1657/head
authorThomas Hindoe Paaboel Andersen <phomes@gmail.com>
Fri, 23 Oct 2015 18:15:17 +0000 (20:15 +0200)
committerThomas Hindoe Paaboel Andersen <phomes@gmail.com>
Fri, 23 Oct 2015 20:35:03 +0000 (22:35 +0200)
No functional change. Just a simplification. A || (!A && B) is
the same as A || B

Introduced in 78a92a5a2306709e4587e332728a76901323ade9

src/tmpfiles/tmpfiles.c

index f636a4d33b31ef24a9690f196c34ab85df8b0b29..09b6ca5c2c1559bb3e78a910af70d1cdf46703b2 100644 (file)
@@ -1585,8 +1585,7 @@ static int clean_item_instance(Item *i, const char* instance) {
         if (fstatat(dirfd(d), "..", &ps, AT_SYMLINK_NOFOLLOW) != 0)
                 return log_error_errno(errno, "stat(%s/..) failed: %m", i->path);
 
-        mountpoint = s.st_dev != ps.st_dev ||
-                     (s.st_dev == ps.st_dev && s.st_ino == ps.st_ino);
+        mountpoint = s.st_dev != ps.st_dev || s.st_ino == ps.st_ino;
 
         log_debug("Cleanup threshold for %s \"%s\" is %s",
                   mountpoint ? "mount point" : "directory",