httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stefan Fritsch ...@sfritsch.de>
Subject Re: svn commit: r924455 - /httpd/httpd/trunk/modules/proxy/mod_proxy_connect.c
Date Thu, 18 Mar 2010 18:23:09 GMT
On Thursday 18 March 2010, Ruediger Pluem wrote:
> On 17.03.2010 21:08, sf@apache.org wrote:
> > Author: sf
> > Date: Wed Mar 17 20:08:42 2010
> > New Revision: 924455
> >
> > URL: http://svn.apache.org/viewvc?rev=924455&view=rev
> > Log:
> > If the client disconnects and the backend continues to send data
> > fast, forcibly close the backend connection.
> >
> > Modified:
> >     httpd/httpd/trunk/modules/proxy/mod_proxy_connect.c
> >
> > Modified: httpd/httpd/trunk/modules/proxy/mod_proxy_connect.c
> > URL:
> > http://svn.apache.org/viewvc/httpd/httpd/trunk/modules/proxy/mod_
> >proxy_connect.c?rev=924455&r1=924454&r2=924455&view=diff
> > =================================================================
> >============= ---
> > httpd/httpd/trunk/modules/proxy/mod_proxy_connect.c (original)
> > +++ httpd/httpd/trunk/modules/proxy/mod_proxy_connect.c Wed Mar
> > 17 20:08:42 2010 @@ -472,7 +477,10 @@ static int
> > proxy_connect_handler(request * Close the socket and clean up
> >       */
> >
> > -    ap_lingering_close(backconn);
> > +    if (client_error)
> > +        apr_socket_close(sock);
> 
> Why do we need to close the socket to the client? IMHO this should
>  be done by the regular mechanism.

This is not the the socket to the client but the socket to the 
backend. Probably it would be done by the pool cleanup anyway, but the 
goal is to avioid a lingering close which would just be a waste of 
bandwidth. Closing the socket explicitly seemed to be the right thing 
to do.

Mime
View raw message