From: Jim Jagielski Date: Tue, 14 Aug 2012 21:14:34 +0000 (+0000) Subject: Editors choice on CHANGES X-Git-Tag: 2.4.3~35 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=bc528d0f91e40856269ef7bfe752fd68e95b32d0;p=apache Editors choice on CHANGES Merge r1361153 from trunk: * Set content type in case we return stale content. Submitted by: rpluem Reviewed/backported by: jim git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/2.4.x@1373115 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/CHANGES b/CHANGES index 5e6ab618eb..c134559f53 100644 --- a/CHANGES +++ b/CHANGES @@ -7,6 +7,9 @@ Changes with Apache 2.4.3 possible XSS for a site where untrusted users can upload files to a location with MultiViews enabled. [Niels Heinen ] + *) mod_cache: Set content type in case we return stale content. + [Ruediger Pluem] + *) Windows: Fix SSL failures on windows with AcceptFilter https none. PR: 52476. [Jeff Trawick] diff --git a/STATUS b/STATUS index 21a0044a77..5a47375e45 100644 --- a/STATUS +++ b/STATUS @@ -88,11 +88,6 @@ RELEASE SHOWSTOPPERS: PATCHES ACCEPTED TO BACKPORT FROM TRUNK: [ start all new proposals below, under PATCHES PROPOSED. ] - * mod_cache: Set content type in case we return stale content. - trunk patch: http://svn.apache.org/viewvc?view=rev&rev=1361153 - 2.4.x patch: trunk patch works - +1: rjung, humbedooh, trawick (needs CHANGES entry) - -0: What should CHANGES say??? PATCHES PROPOSED TO BACKPORT FROM TRUNK: [ New proposals should be added at the end of the list ] diff --git a/modules/cache/mod_cache.c b/modules/cache/mod_cache.c index 720d81a558..e75f01d34b 100644 --- a/modules/cache/mod_cache.c +++ b/modules/cache/mod_cache.c @@ -1655,6 +1655,9 @@ static void cache_insert_error_filter(request_rec *r) r->err_headers_out = cache->stale_handle->resp_hdrs; + ap_set_content_type(r, apr_table_get( + cache->stale_handle->resp_hdrs, "Content-Type")); + /* add a revalidation warning */ warn_head = apr_table_get(r->err_headers_out, "Warning"); if ((warn_head == NULL) || ((warn_head != NULL)