diff options
author | Eric Wong <e@80x24.org> | 2017-02-28 23:00:25 +0000 |
---|---|---|
committer | Eric Wong <e@80x24.org> | 2017-03-01 00:24:04 +0000 |
commit | 73e1ce827faad59bfcaff0bc758c8255a5e4f747 (patch) | |
tree | 24cc4a05c15ec6860db1f04df73eb5af06024c88 | |
parent | c8f06be298d667ba85573668ee916680a258c2c7 (diff) | |
download | unicorn-73e1ce827faad59bfcaff0bc758c8255a5e4f747.tar.gz |
Killing the master process may lead to the worker dying on its own (as designed); before kill(1) has had an opportunity to send the second kill(2) syscall on the worker process. Killing the worker before the master might also lead to a needless respawn, so merely kill the master and let the worker follow it in death. This race condition occasionally caused test failures on slow, uniprocessor hardware.
-rwxr-xr-x | t/t0011-active-unix-socket.sh | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/t/t0011-active-unix-socket.sh b/t/t0011-active-unix-socket.sh index d256f5c..fae0b6c 100755 --- a/t/t0011-active-unix-socket.sh +++ b/t/t0011-active-unix-socket.sh @@ -52,7 +52,7 @@ t_begin "worker pid unchanged (again)" && { } t_begin "nuking the existing Unicorn succeeds" && { - kill -9 $unicorn_pid $worker_pid + kill -9 $unicorn_pid while kill -0 $unicorn_pid do sleep 1 |