]> git.kaiwu.me - nginx.git/commit
merge r3294, r3305:
authorIgor Sysoev <igor@sysoev.ru>
Mon, 1 Feb 2010 15:49:36 +0000 (15:49 +0000)
committerIgor Sysoev <igor@sysoev.ru>
Mon, 1 Feb 2010 15:49:36 +0000 (15:49 +0000)
commitc419414db440c298006d814936de28964d654b38
tree3d86adc0fd3c6aa0c41633d4f95eea6b5d8f263b
parent95a5ecb1ac78b14b759ada666b2114783fc1c2d2
merge r3294, r3305:

Fix a bug introduced in r2032: After a child process has read a terminate
message from a channel, the process tries to read the channel again.
The kernel (at least FreeBSD) may preempt the process and sends a SIGIO
signal to a master process. The master process sends a new terminate message,
the kernel switches again to the the child process, and the child process
reads the messages instead of an EAGAIN error. And this may repeat over
and over. Being that the child process can not exit the cycle and test
the termination flag set by the message handler.

The fix disallow the master process to send a new terminate message on
SIGIO signal reception. It may send the message only on SIGALARM signal.
src/os/unix/ngx_process_cycle.c