lxc/0006-conf.c-fix-bug-when-set-no-ro-mount-mount-propagatio.patch
2019-12-25 15:57:42 +08:00

40 lines
1.0 KiB
Diff

From d0ea541f9360eed1cb6beb91a0e69f1afa0b5031 Mon Sep 17 00:00:00 2001
From: tanyifeng <tanyifeng1@huawei.com>
Date: Fri, 11 Jan 2019 16:55:01 +0800
Subject: [PATCH 006/131] conf.c: fix bug when set no ro mount, mount
propagation will be skipped
Signed-off-by: LiFeng <lifeng68@huawei.com>
---
src/lxc/conf.c | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/src/lxc/conf.c b/src/lxc/conf.c
index 18753d18..37a5ff79 100644
--- a/src/lxc/conf.c
+++ b/src/lxc/conf.c
@@ -2087,6 +2087,9 @@ static int mount_entry(const char *fsname, const char *target,
}
}
+#ifdef HAVE_STATVFS
+ skipremount:
+#endif
if (pflags) {
ret = mount(NULL, target, NULL, pflags, NULL);
if (ret < 0) {
@@ -2103,10 +2106,6 @@ static int mount_entry(const char *fsname, const char *target,
DEBUG("Changed mount propagation for \"%s\"", target);
}
-
-#ifdef HAVE_STATVFS
-skipremount:
-#endif
DEBUG("Mounted \"%s\" on \"%s\" with filesystem type \"%s\"",
srcpath ? srcpath : "(null)", target, fstype);
--
2.23.0