Alain Bench <[EMAIL PROTECTED]> writes: > | /* Return if we have no intention of further downloading. */ > | if (!(*dt & RETROKF) || (*dt & HEAD_ONLY)) > | { > | /* In case the caller cares to look... */ > | hs->len = 0L; > | hs->res = 0; > | FREE_MAYBE (type); > | FREE_MAYBE (all_headers); > | CLOSE_INVALIDATE (sock); /* would be CLOSE_FINISH, but there > | might be more bytes in the body. */ > | return RETRFINISHED; > | } > > ...changing CLOSE_INVALIDATE to CLOSE_FINISH.
That's exactly the right change. As the comment implies, the only reason for using CLOSE_INVALIDATE is fear that a misbehaving CGI might send more data, thus confusing the next request or even causing deadlock while writing the request to the server. When keep-alive connections are not in use (which can be forced with --no-http-keep-alive), CLOSE_INVALIDATE and CLOSE_FINISH are pretty much identical.