[CRIU] [PATCH] mem: stop searching a parent vma if we found one

Andrey Vagin avagin at openvz.org
Tue May 13 05:09:56 PDT 2014


A parent vma can be only one.

Fixes: 57d25e7cea12 ("mm: fix expression to determine which vma-s can be shared")
Reported-by: Filipe Brandenburger <filbranden at google.com>
Signed-off-by: Andrey Vagin <avagin at openvz.org>
---
 cr-restore.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/cr-restore.c b/cr-restore.c
index 897c3fc..91cce50 100644
--- a/cr-restore.c
+++ b/cr-restore.c
@@ -261,6 +261,8 @@ static int map_private_vma(pid_t pid, struct vma_area *vma, void **tgt_addr,
 		pr_info("COW 0x%016"PRIx64"-0x%016"PRIx64" 0x%016"PRIx64" vma\n",
 			vma->e->start, vma->e->end, vma->e->pgoff);
 		paddr = decode_pointer(p->premmaped_addr);
+
+		break;
 	}
 
 	*pvma = p;
-- 
1.8.5.3



More information about the CRIU mailing list