[3/4] restore: Don't ignore errors on wait in restore_one_zombie

Submitted by Cyrill Gorcunov on Dec. 7, 2018, 11:57 a.m.

Details

Message ID 20181207115712.24130-4-gorcunov@gmail.com
State New
Series "restore: Fix potential hung on restore"
Headers show

Commit Message

Cyrill Gorcunov Dec. 7, 2018, 11:57 a.m.
Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
---
 criu/cr-restore.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

Patch hide | download patch | download mbox

diff --git a/criu/cr-restore.c b/criu/cr-restore.c
index ea4a599b303c..4153ee5535bf 100644
--- a/criu/cr-restore.c
+++ b/criu/cr-restore.c
@@ -1024,7 +1024,8 @@  static int restore_one_zombie(CoreEntry *core)
 	prctl(PR_SET_NAME, (long)(void *)core->tc->comm, 0, 0, 0);
 
 	if (task_entries != NULL) {
-		wait_exiting_children("zombie");
+		if (wait_exiting_children("zombie"))
+			return -1;
 		zombie_prepare_signals();
 	}