On 19 Nov 2010, at 8:33 AM, Ruediger Pluem wrote:

Modified: httpd/httpd/trunk/modules/proxy/mod_proxy_http.c
URL: 
http://svn.apache.org/viewvc/httpd/httpd/trunk/modules/proxy/mod_proxy_http.c?rev=1035605&r1=1035604&r2=1035605&view=diff
=
=
=
=
=
=
=
=
=
=====================================================================
--- httpd/httpd/trunk/modules/proxy/mod_proxy_http.c (original)
+++ httpd/httpd/trunk/modules/proxy/mod_proxy_http.c Tue Nov 16 12:08:38 2010
                       * left waiting for a slow client to eventually
@@ -1930,6 +1946,7 @@ apr_status_t ap_proxy_http_process_respo

/* make sure we always clean up after ourselves */
                    apr_brigade_cleanup(pass_bb);
+                    apr_brigade_cleanup(bb);

Is this safe? If we released the backend connection we know that bb is empty, because we already called apr_brigade_cleanup(bb);, but what if the pool and the allocator of the backend connection have died meanwhile? Is this operation still safe in this case?

bb is created like so:

    bb = apr_brigade_create(p, c->bucket_alloc);

In other words, from the front side connection's allocator. When we've closed early, bb will be empty, which means this is a noop, but the brigade is guaranteed to still exist.

Regards,
Graham
--

Reply via email to