httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dean Gaudet <>
Subject Re: Apache Week issue 153 (12th March 1999)
Date Fri, 12 Mar 1999 17:59:09 GMT

On Fri, 12 Mar 1999, Apache Week wrote:

> Modules will be allowed to use SIGPIPE
>    The current version of Apache traps the SIGPIPE signal to see if the
>    connection to the client (browser) has been lost. However this means
>    that Apache modules cannot use SIGPIPE if they have outgoing
>    connections to, say, a database or other remote system. The core of
>    Apache has been updated now so that it does not use or trap SIGPIPE at
>    all. Instead, all functions which write to or read from the client
>    check their error status and if the connection is lost they set the
>    "aborted" field in the connection data structure.
>    This will allow modules to trap SIGPIPE so that they can monitor their
>    own connection. Modules can also check for a lost connection more
>    easily, by looking at the aborted field.

This isn't quite the whole story -- modules are allowed to trap it while
they're doing their own socket work, but they must immediately restore it
before returning to the core or calling another module. 

Anything else is a broken module. 

Along with that fd check I mentioned a while back, a signal handler check
would be a useful debugging option. 


View raw message