mirror of
https://github.com/checkpoint-restore/criu
synced 2025-09-01 06:45:35 +00:00
mount: Close old service descriptor in mntns_collect_root
We're about to collect root several times in a row, so keeping the old one isn't required. Signed-off-by: Andrey Vagin <avagin@openvz.org> Signed-off-by: Pavel Emelyanov <xemul@parallels.com>
This commit is contained in:
committed by
Pavel Emelyanov
parent
e8ac085af8
commit
67456e90ac
2
mount.c
2
mount.c
@@ -1531,6 +1531,8 @@ int mntns_collect_root(pid_t pid)
|
|||||||
int ret;
|
int ret;
|
||||||
char path[PATH_MAX + 1];
|
char path[PATH_MAX + 1];
|
||||||
|
|
||||||
|
close_service_fd(ROOT_FD_OFF);
|
||||||
|
|
||||||
if (!(current_ns_mask & CLONE_NEWNS)) {
|
if (!(current_ns_mask & CLONE_NEWNS)) {
|
||||||
/*
|
/*
|
||||||
* If criu and tasks we dump live in the same mount
|
* If criu and tasks we dump live in the same mount
|
||||||
|
Reference in New Issue
Block a user