From defdb96b9b5260c5299de29e290333f81f91f8ac Mon Sep 17 00:00:00 2001 From: Pavel Emelyanov Date: Fri, 31 Oct 2014 13:49:00 +0400 Subject: [PATCH] mount: Invert check for shared mounts check Introduced by eb214be2, the empty mnt_share list cannot produce the list_first_entry element :) Signed-off-by: Pavel Emelyanov Acked-by: Andrew Vagin --- mount.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mount.c b/mount.c index 1de37a03b..f4c0113f8 100644 --- a/mount.c +++ b/mount.c @@ -376,7 +376,7 @@ static int validate_shared(struct mount_info *m) { struct mount_info *ct, *t; - if (!list_empty(&m->parent->mnt_share)) + if (list_empty(&m->parent->mnt_share)) return 0; t = list_first_entry(&m->parent->mnt_share, struct mount_info, mnt_share);