At 01:47 PM 6/29/2004, Mathihalli, Madhusudan wrote:

>: -----Original Message-----
>: From: Colm MacCarthaigh [mailto:[EMAIL PROTECTED] 
>[SNIP]
>: > Upon doing a "apachectl stop", shouldn't the CGI processes 
>: (forked by 
>: > mod_cgid or mod_cgi) also exit ?
>: 
>: It depends, if they call setsid() and so on - there's no 
>: particular reason they should. Ordinarily - yes.
>
>In case of setsid(), I have no idea what the behaviour should be :-). 
>
>For the 'Ordinarily' case - it doesn't do it today. It can be easily
>done by having a "kill (0, SIGTERM)" just before mod_cgid/apache exits -
>but I don't know if it's portable.

Wouldn't a SIGHUP make more sense?  Some CGI's may override, seeing
as they were invoked to perform an operation (non-abortable) as opposed
to retrieving results.  The client does HUP in those cases, from a coder's
point of view.


Reply via email to