Commit 78ccf7bd authored by Simon's avatar Simon Committed by Poul-Henning Kamp

Decrease sleep time when waiting for child to die.

parent 05780b63
......@@ -519,11 +519,11 @@ mgt_reap_child(void)
XXXAN(vsb);
/* Wait for child to die */
for (i = 0; i < mgt_param.cli_timeout; i++) {
for (i = 0; i < mgt_param.cli_timeout * 10; i++) {
r = waitpid(child_pid, &status, WNOHANG);
if (r == child_pid)
break;
(void)sleep(1);
(void)usleep(100000);
}
if (r == 0) {
VSB_printf(vsb, "Child (%jd) not dying, killing", (intmax_t)r);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment