[CRIU] [PATCH 2/3] zdtm: don't lock a mutex twice

Andrei Vagin avagin at openvz.org
Fri Jan 20 12:21:26 PST 2017


From: Andrei Vagin <avagin at virtuozzo.com>

CID 174786 (#1 of 1): Double lock (LOCK)
3. double_lock: pthread_mutex_lock locks init_lock while it is locked.

Signed-off-by: Andrei Vagin <avagin at virtuozzo.com>
---
 test/zdtm/static/clone_fs.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/test/zdtm/static/clone_fs.c b/test/zdtm/static/clone_fs.c
index 5cebea5..4afe50f 100644
--- a/test/zdtm/static/clone_fs.c
+++ b/test/zdtm/static/clone_fs.c
@@ -81,8 +81,6 @@ int main(int argc, char **argv)
 		return 1;
 	}
 
-	pthread_mutex_lock(&init_lock);
-
 	ret = kcmp(KCMP_FS, gettid(), tid, 0, 0);
 	if (ret)
 		exit(1);
-- 
2.7.4



More information about the CRIU mailing list