Commit 7f26d650 authored by Poul-Henning Kamp's avatar Poul-Henning Kamp

Under circumstances I don't understand, test p00006 takes 52 seconds

on osx.

Use the cli_timeout to control how long the MGR waits before killing
the worker process, and give this test 60 seconds.
parent acb59df6
......@@ -483,14 +483,20 @@ mgt_reap_child(void)
ev_listen = NULL;
}
/* Wait 10 seconds for child to die */
for (i = 0; i < 10; i++) {
/* Compose obituary */
vsb = VSB_new_auto();
XXXAN(vsb);
/* Wait for child to die */
for (i = 0; i < mgt_param.cli_timeout; i++) {
r = waitpid(child_pid, &status, WNOHANG);
if (r == child_pid)
break;
(void)sleep(1);
}
if (r == 0) {
VSB_printf(vsb, "Child (%jd) not dying, killing", (intmax_t)r);
/* Kick it Jim... */
if (MGT_FEATURE(FEATURE_NO_COREDUMP))
(void)kill(child_pid, SIGKILL);
......@@ -504,9 +510,6 @@ mgt_reap_child(void)
MAC_reopen_sockets(NULL);
/* Compose obituary */
vsb = VSB_new_auto();
XXXAN(vsb);
VSB_printf(vsb, "Child (%jd) %s", (intmax_t)r,
status ? "died" : "ended");
if (WIFEXITED(status) && WEXITSTATUS(status)) {
......
......@@ -12,6 +12,7 @@ server s1 {
varnish v1 \
-arg "-sdeprecated_persistent,${tmpdir}/_.per,10m" \
-arg "-pcli_timeout=60"
-arg "-pban_lurker_sleep=0" \
-vcl+backend { } -start
......
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