mount: don't mount an external mount before all members of a shared group

otherwise this mount will not be propagated into non-existant mounts

Signed-off-by: Andrew Vagin <avagin@virtuozzo.com>
Signed-off-by: Pavel Emelyanov <xemul@virtuozzo.com>
This commit is contained in:
Andrew Vagin 2016-03-05 00:38:00 +03:00 committed by Pavel Emelyanov
parent b4ffeeeba2
commit cebc6c3796

View file

@ -2416,7 +2416,7 @@ static bool can_mount_now(struct mount_info *mi)
return true;
if (mi->external)
return true;
goto shared;
/*
* We're the slave peer:
@ -2439,6 +2439,7 @@ static bool can_mount_now(struct mount_info *mi)
if (!fsroot_mounted(mi) && (mi->bind == NULL && !mi->need_plugin && !mi->external))
return false;
shared:
if (mi->parent->shared_id) {
struct mount_info *p = mi->parent, *n;