Blame SOURCES/httpd-2.4.6-r1621601.patch
|
|
41a6c3 |
--- a/modules/proxy/mod_proxy_http.c 2014/08/31 16:06:36 1621600
|
|
|
41a6c3 |
+++ b/modules/proxy/mod_proxy_http.c 2014/08/31 16:07:45 1621601
|
|
|
41a6c3 |
@@ -1652,6 +1652,18 @@
|
|
|
41a6c3 |
if (!r->header_only && /* not HEAD request */
|
|
|
41a6c3 |
(proxy_status != HTTP_NO_CONTENT) && /* not 204 */
|
|
|
41a6c3 |
(proxy_status != HTTP_NOT_MODIFIED)) { /* not 304 */
|
|
|
41a6c3 |
+ const char *tmp;
|
|
|
41a6c3 |
+ /* Add minimal headers needed to allow http_in filter
|
|
|
41a6c3 |
+ * detecting end of body without waiting for a timeout. */
|
|
|
41a6c3 |
+ if ((tmp = apr_table_get(r->headers_out, "Transfer-Encoding"))) {
|
|
|
41a6c3 |
+ apr_table_set(backend->r->headers_in, "Transfer-Encoding", tmp);
|
|
|
41a6c3 |
+ }
|
|
|
41a6c3 |
+ else if ((tmp = apr_table_get(r->headers_out, "Content-Length"))) {
|
|
|
41a6c3 |
+ apr_table_set(backend->r->headers_in, "Content-Length", tmp);
|
|
|
41a6c3 |
+ }
|
|
|
41a6c3 |
+ else if (te) {
|
|
|
41a6c3 |
+ apr_table_set(backend->r->headers_in, "Transfer-Encoding", te);
|
|
|
41a6c3 |
+ }
|
|
|
41a6c3 |
ap_discard_request_body(backend->r);
|
|
|
41a6c3 |
}
|
|
|
41a6c3 |
return proxy_status;
|