From f7449735ad61d51def65b8e6c8ee0f2becb6765e Mon Sep 17 00:00:00 2001 From: Colin Ian King Date: Tue, 19 May 2020 09:18:12 +0100 Subject: [PATCH 09/28] stress-dev: remove sleep and return EXIT_SUCCESS on child exit The sleep is surplus to requirements, so remove it. Also make child exit with EXIT_SUCCESS when it successfully terminates. Signed-off-by: Colin Ian King --- stress-dev.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/stress-dev.c b/stress-dev.c index 9cde82549785..2eeb72c8cc21 100644 --- a/stress-dev.c +++ b/stress-dev.c @@ -1532,7 +1532,6 @@ again: (void)setpgid(pid, g_pgrp); /* Parent, wait for child */ wret = shim_waitpid(pid, &status, 0); - sleep(2); if (wret < 0) { if (errno != EINTR) pr_dbg("%s: waitpid(): errno=%d (%s)\n", @@ -1601,7 +1600,7 @@ again: pthread_join(pthreads[i], NULL); } stress_hash_delete(dev_hash_table); - _exit(!keep_stressing_flag()); + _exit(EXIT_SUCCESS); } } while (keep_stressing()); -- 2.21.3