summaryrefslogtreecommitdiff
path: root/src/core/namespace.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2015-05-13 14:04:55 +0200
committerLennart Poettering <lennart@poettering.net>2015-05-13 14:07:26 +0200
commit5a8af538aee99741ab492506b4284fdd26b597d1 (patch)
tree5c92fe3e9d04c65659b7141213b776ed312ff336 /src/core/namespace.c
parent4df3277881cffcd3bc9a5238203d6af7e1fd960f (diff)
nspawn: rework custom mount point order, and add support for overlayfs
Previously all bind mount mounts were applied in the order specified, followed by all tmpfs mounts in the order specified. This is problematic, if bind mounts shall be placed within tmpfs mounts. This patch hence reworks the custom mount point logic, and alwas applies them in strict prefix-first order. This means the order of mounts specified on the command line becomes irrelevant, the right operation will always be executed. While we are at it this commit also adds native support for overlayfs mounts, as supported by recent kernels.
Diffstat (limited to 'src/core/namespace.c')
-rw-r--r--src/core/namespace.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/core/namespace.c b/src/core/namespace.c
index 718da2384d..bee2839f54 100644
--- a/src/core/namespace.c
+++ b/src/core/namespace.c
@@ -87,7 +87,7 @@ static int mount_path_compare(const void *a, const void *b) {
d = path_compare(p->path, q->path);
- if (!d) {
+ if (d == 0) {
/* If the paths are equal, check the mode */
if (p->mode < q->mode)
return -1;