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

mount/restore: leave ns_mountpoint NULL for aux binfmt_misc mount

On dump, yes, mountpoint and ns_mountpoint are the same, but on restore
they don't and puting something like "<root_yard>/binfmt_misc" to
ns_mountpoint is wrong, let's leave ns_mountpoint NULL, this mount
should not be compared by ns_mountpoint with other mounts anyway.

Signed-off-by: Pavel Tikhomirov <ptikhomirov@virtuozzo.com>
This commit is contained in:
Pavel Tikhomirov
2022-01-13 17:45:46 +03:00
committed by Andrei Vagin
parent 16085b5e67
commit 4736a7240e

View File

@@ -1589,7 +1589,8 @@ static __maybe_unused struct mount_info *add_cr_time_mount(struct mount_info *ro
mi->mountpoint = xmalloc(len + strlen(path) + 1); mi->mountpoint = xmalloc(len + strlen(path) + 1);
if (!mi->mountpoint) if (!mi->mountpoint)
goto err; goto err;
mi->ns_mountpoint = mi->mountpoint; if (!rst)
mi->ns_mountpoint = mi->mountpoint;
if (!add_slash) if (!add_slash)
sprintf(mi->mountpoint, "%s%s", root->mountpoint, path); sprintf(mi->mountpoint, "%s%s", root->mountpoint, path);
else else