summaryrefslogtreecommitdiff
path: root/src/core/mount-setup.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2015-09-07 13:42:47 +0200
committerLennart Poettering <lennart@poettering.net>2015-09-07 13:42:47 +0200
commit75f86906c52735c98dc0aa7e24b773edb42ee814 (patch)
treed2d0701f8df51d5a09586073ebd387bb831743e7 /src/core/mount-setup.c
parent47f5a38cdf98a220d6a0d4eb11a710a0a42ae5c4 (diff)
basic: rework virtualization detection API
Introduce a proper enum, and don't pass around string ids anymore. This simplifies things quite a bit, and makes virtualization detection more similar to architecture detection.
Diffstat (limited to 'src/core/mount-setup.c')
-rw-r--r--src/core/mount-setup.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/core/mount-setup.c b/src/core/mount-setup.c
index c6f3569915..e84f80b61b 100644
--- a/src/core/mount-setup.c
+++ b/src/core/mount-setup.c
@@ -164,7 +164,7 @@ static int mount_one(const MountPoint *p, bool relabel) {
return 0;
/* Skip securityfs in a container */
- if (!(p->mode & MNT_IN_CONTAINER) && detect_container(NULL) > 0)
+ if (!(p->mode & MNT_IN_CONTAINER) && detect_container() > 0)
return 0;
/* The access mode here doesn't really matter too much, since
@@ -385,7 +385,7 @@ int mount_setup(bool loaded_policy) {
* nspawn and the container tools work out of the box. If
* specific setups need other settings they can reset the
* propagation mode to private if needed. */
- if (detect_container(NULL) <= 0)
+ if (detect_container() <= 0)
if (mount(NULL, "/", NULL, MS_REC|MS_SHARED, NULL) < 0)
log_warning_errno(errno, "Failed to set up the root directory for shared mount propagation: %m");