summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/core/main.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/core/main.c b/src/core/main.c
index 7b039835a8..01a6d41fb4 100644
--- a/src/core/main.c
+++ b/src/core/main.c
@@ -1437,7 +1437,7 @@ int main(int argc, char *argv[]) {
/* Mount /proc, /sys and friends, so that /proc/cmdline and
* /proc/$PID/fd is available. */
- if (geteuid() == 0 && !getenv("SYSTEMD_SKIP_API_MOUNTS")) {
+ if (getpid() == 1) {
r = mount_setup(loaded_policy);
if (r < 0)
goto finish;