Re: [EXIM] accept() errors instead of accepting when network…

Página superior
Eliminar este mensaje
Responder a este mensaje
Autor: D. J. Bernstein
Fecha:  
A: exim-users
Asunto: Re: [EXIM] accept() errors instead of accepting when network unreachable
Greg A. Woods writes:
> * Interactive UNIX 2.2 has a bug in accept(). If accept() is
> * interrupted by an alarm signal, accept() does not return from
> * waiting for a connection with errno set to EINTR.


That's the standard BSD 4.2 signal behavior.

Restarting became optional in BSD 4.3 with siginterrupt() and in later
systems with SA_RESTART in sigaction(). Try it!

> This made me suspect that the
> code which should have set errno to EINTR and returned from accept() was
> doing other evil things instead -- evil things which eventually resulted
> in enough corruption that the TCP stack was useless.


Other than this wild speculation, is there any substance to your claim
of ``lots of STREAMS based TCP/IP stacks where completely killing and
restarting the daemon, or even rebooting sometimes, is still required
when accept(2) gets itself tied in a knot''?

---Dan
1000 recipients, 28.8 modem, 10 seconds. http://pobox.com/~djb/qmail/mini.html

--
*** Exim information can be found at http://www.exim.org/ ***