httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Rob Hartill <hart...@ooo.lanl.gov>
Subject Re: require-client functionality
Date Tue, 07 May 1996 15:19:52 GMT
 
> Hmmm ... not sure about that, as the 1 is a side effect of the buggy close you
> added. Can you try this; first, confirm that bclose actually is closing fd 1
> when you have your close() in http_main.c. Then, take out the close in
> http_main.c and add an extra close(fb->fd) in bclose() [yeah, I know this
> should have no effect but it seems to be what is happening] and test again.

close(1) before the accept solves my problem and bclose returns 0.

without close(1) = problem

2 x close(fb->fd) + no close(1)   = problem + 2nd close returns -1
fb->fd = 8, so I didn't think that'd work.

now what?   :-)

I think we can get away with "close(1)" before the main child
loop (which works). Is it safe to shutdown the stdout here? I'd
guess that it is since we only talk to stderr, right?.

As I said before, the perl CGI needs to close stdout, so this ties
in with running background processes independently of the parent.

Was 1.1b0 giving CGI dup'ed versions of stdout that may have the same
effect?  I vaguely remember some dup(1), close(1) type commands in the
really old apache/ncsa code.


rob

Mime
View raw message