[CRIU] [PATCH] mem: Do not hide error from add_shmem_area

Pavel Emelyanov xemul at virtuozzo.com
Fri Sep 2 07:07:31 PDT 2016


Signed-off-by: Pavel Emelyanov <xemul at virtuozzo.com>
---
 criu/mem.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/criu/mem.c b/criu/mem.c
index a94a378..63acec3 100644
--- a/criu/mem.c
+++ b/criu/mem.c
@@ -365,14 +365,14 @@ again:
 				BUG_ON(delayed_dump);
 
 				ret = dump_pages(pp, ctl, args, &xfer, false);
-				if (ret)
-					goto out_xfer;
-				page_pipe_reinit(pp);
-				goto again;
+				if (!ret) {
+					page_pipe_reinit(pp);
+					goto again;
+				}
 			}
-			if (ret < 0)
-				goto out_xfer;
 		}
+		if (ret < 0)
+			goto out_xfer;
 	}
 
 	if (lazy)
-- 
2.5.0


More information about the CRIU mailing list