]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
core: move very long argument to a separate statement
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Thu, 15 Feb 2018 09:10:01 +0000 (10:10 +0100)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Thu, 15 Feb 2018 09:10:01 +0000 (10:10 +0100)
I like compact, but this was a bit too much.

src/core/namespace.c

index 70089f212a57570f26891f942b3adbb4b65f51db..72f0d038d111012b7bad1566242a7e64b783534b 100644 (file)
@@ -735,6 +735,7 @@ static int mount_entry_chase(
 
         char *chased;
         int r;
+        unsigned flags = 0;
 
         assert(m);
 
@@ -742,9 +743,19 @@ static int mount_entry_chase(
          * chase the symlinks on our own first. This is called for the destination path, as well as the source path (if
          * that applies). The result is stored in "location". */
 
-        r = chase_symlinks(path, root_directory,
-                           IN_SET(m->mode, BIND_MOUNT, BIND_MOUNT_RECURSIVE, PRIVATE_TMP, PRIVATE_VAR_TMP, PRIVATE_DEV, BIND_DEV, EMPTY_DIR, SYSFS, PROCFS) ? CHASE_NONEXISTENT : 0,
-                           &chased);
+        if (IN_SET(m->mode,
+                   BIND_MOUNT,
+                   BIND_MOUNT_RECURSIVE,
+                   PRIVATE_TMP,
+                   PRIVATE_VAR_TMP,
+                   PRIVATE_DEV,
+                   BIND_DEV,
+                   EMPTY_DIR,
+                   SYSFS,
+                   PROCFS))
+                flags |= CHASE_NONEXISTENT;
+
+        r = chase_symlinks(path, root_directory, flags, &chased);
         if (r == -ENOENT && m->ignore) {
                 log_debug_errno(r, "Path %s does not exist, ignoring.", path);
                 return 0;