2
0
mirror of https://github.com/checkpoint-restore/criu synced 2025-08-22 09:58:09 +00:00

mount: Don't create kids with CLONE_NEWNS

We explicitly setns() every single task by hands when restoring
mount namespaces, they can be created without the NEWNS flag.

Signed-off-by: Pavel Emelyanov <xemul@parallels.com>
Acked-by: Andrey Vagin <avagin@parallels.com>
This commit is contained in:
Pavel Emelyanov 2014-05-12 14:20:17 +04:00
parent 63c9478a4a
commit d513098f3c

View File

@ -662,6 +662,14 @@ static int prepare_pstree_kobj_ids(void)
set_mask:
item->rst->clone_flags = cflags;
if (parent)
/*
* Mount namespaces are setns()-ed at
* restore_task_mnt_ns() explicitly,
* no need in creating it with its own
* temporary namespace
*/
item->rst->clone_flags &= ~CLONE_NEWNS;
cflags &= CLONE_ALLNS;