[1/2] mount: remove an extra condition from mounts_equal()

Submitted by Andrei Vagin on May 5, 2016, 2:22 a.m.

Details

Message ID 1462414921-16804-1-git-send-email-avagin@openvz.org
State Accepted
Series "Series without cover letter"
Commit d923184f9bdbda62991c57a20595f1a9633adfb9
Headers show

Commit Message

Andrei Vagin May 5, 2016, 2:22 a.m.
From: Andrew Vagin <avagin@virtuozzo.com>

Two mounts can be equal even it they are mounted in
directories with different names.

Signed-off-by: Andrew Vagin <avagin@virtuozzo.com>
---
 criu/mount.c | 2 --
 1 file changed, 2 deletions(-)

Patch hide | download patch | download mbox

diff --git a/criu/mount.c b/criu/mount.c
index 3b30003..a3c830f 100644
--- a/criu/mount.c
+++ b/criu/mount.c
@@ -333,8 +333,6 @@  static bool mounts_equal(struct mount_info *a, struct mount_info *b)
 		return false;
 	if (strcmp(a->root, b->root))
 		return false;
-	if (strcmp(basename(a->mountpoint), basename(b->mountpoint)))
-		return false;
 
 	return true;
 }

Comments

Pavel Emelianov May 6, 2016, 12:17 p.m.
Makes sense, thanks.