The following pull request was submitted through Github.
It can be accessed and reviewed at: https://github.com/lxc/lxc/pull/3308

This e-mail was sent by the LXC bot, direct replies will not reach the author
unless they happen to be subscribed to this list.

=== Description (from pull-request) ===
Signed-off-by: Christian Brauner <christian.brau...@ubuntu.com>
From 15f3e22b00e3b25b1cf5ae031681277d46a040cd Mon Sep 17 00:00:00 2001
From: Christian Brauner <christian.brau...@ubuntu.com>
Date: Thu, 19 Mar 2020 13:27:51 +0100
Subject: [PATCH] conf: flatten logic in mount_entry()

Signed-off-by: Christian Brauner <christian.brau...@ubuntu.com>
---
 src/lxc/conf.c | 8 +++-----
 1 file changed, 3 insertions(+), 5 deletions(-)

diff --git a/src/lxc/conf.c b/src/lxc/conf.c
index 5c280c3815..066a600d66 100644
--- a/src/lxc/conf.c
+++ b/src/lxc/conf.c
@@ -1875,11 +1875,9 @@ static int mount_entry(const char *fsname, const char 
*target,
                         * does not have any flags which are not already in
                         * mountflags, then skip the remount.
                         */
-                       if (!(mountflags & MS_REMOUNT)) {
-                               if (!(required_flags & ~mountflags)) {
-                                       DEBUG("Mountflags already were %lu, 
skipping remount", mountflags);
-                                       goto skipremount;
-                               }
+                       if (!(mountflags & MS_REMOUNT) && !(required_flags & 
~mountflags)) {
+                               DEBUG("Mountflags already were %lu, skipping 
remount", mountflags);
+                               goto skipremount;
                        }
 
                        mountflags |= required_flags;
_______________________________________________
lxc-devel mailing list
lxc-devel@lists.linuxcontainers.org
http://lists.linuxcontainers.org/listinfo/lxc-devel

Reply via email to