Skip to content
Commit a4239104 authored by Kirill Tkhai's avatar Kirill Tkhai Committed by Pavel Emelyanov
Browse files

mounts: Skip already bound siblings in propagate_siblings()



This function may be called several times for a mnt_share family.
The second call with a mi, which was not a bind source during the
first call, leads to double dependence:

a <-> b <-> c

1)propagate_siblings(a)

b->bind = a;
c->bind = a;

2)propagate_siblings(b)

c->bind = b;
(a is not set, because its mounted is 1).

So during c's bind mount criu use b's root and refers to a wrong
directory.

The reproduction: mntns_root_bind02 test.

The patch fixes the problem.

Signed-off-by: default avatarKirill Tkhai <ktkhai@virtuozzo.com>
Acked-by: default avatarAndrew Vagin <avagin@virtuozzo.com>
Signed-off-by: default avatarPavel Emelyanov <xemul@virtuozzo.com>
parent 076c73b2
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment