]> git.ipfire.org Git - thirdparty/systemd.git/commit - src/basic/process-util.c
process-util: add a new FORK_MOUNTNS_SLAVE flag for safe_fork()
authorLennart Poettering <lennart@poettering.net>
Fri, 23 Mar 2018 19:52:46 +0000 (20:52 +0100)
committerLennart Poettering <lennart@poettering.net>
Thu, 24 May 2018 15:01:57 +0000 (17:01 +0200)
commite2047ba9ed68aa223715f25e156aeb0665c884ce
tree27b9c8277c613df2d08fb72ccad31e6f4c722074
parent03bcb6d408be7308088a7233dfe864538cf055b0
process-util: add a new FORK_MOUNTNS_SLAVE flag for safe_fork()

We already have a flag for creating a new mount namespace for the child.
Let's add an extension to that: a new FORK_MOUNTNFS_SLAVE flag. When
used in combination will mark all mounts in the child namespace as
MS_SLAVE so that the child can freely mount or unmount stuff but it
won't leak into the parent.
src/basic/process-util.c
src/basic/process-util.h
src/shared/dissect-image.c