httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rpl...@apache.org
Subject svn commit: r425725 - in /httpd/httpd/branches/2.2.x: CHANGES STATUS modules/cache/cache_storage.c
Date Wed, 26 Jul 2006 13:04:27 GMT
Author: rpluem
Date: Wed Jul 26 06:04:27 2006
New Revision: 425725

URL: http://svn.apache.org/viewvc?rev=425725&view=rev
Log:
Merge r410370 from trunk:

* Keep the Content-Type for successfully revalidated
  cached objects, by unsetting possible Content-Type headers in
  r->headers_out and r->err_headers_out as they may be different to what
  we have received from the cache.
  Actually they are not needed as r->content_type set by
  ap_set_content_type a few lines above will be used in the store_headers
  functions of the storage providers as a fallback and the HTTP_HEADER filter
  does overwrite the Content-Type header with r->content_type anyway.

PR: 39647
Submitted by: rpluem
Reviewed by: rpluem, pquerna, fielding

Modified:
    httpd/httpd/branches/2.2.x/CHANGES
    httpd/httpd/branches/2.2.x/STATUS
    httpd/httpd/branches/2.2.x/modules/cache/cache_storage.c

Modified: httpd/httpd/branches/2.2.x/CHANGES
URL: http://svn.apache.org/viewvc/httpd/httpd/branches/2.2.x/CHANGES?rev=425725&r1=425724&r2=425725&view=diff
==============================================================================
--- httpd/httpd/branches/2.2.x/CHANGES [utf-8] (original)
+++ httpd/httpd/branches/2.2.x/CHANGES [utf-8] Wed Jul 26 06:04:27 2006
@@ -1,6 +1,9 @@
                                                         -*- coding: utf-8 -*-
 Changes with Apache 2.2.3
 
+  *) mod_cache: Do not overwrite the Content-Type in the cache, for
+     successfully revalidated cached objects. PR 39647. [Ruediger Pluem]
+
   *) mod_speling: Add directive to deal with case corrections only
      and ignore other misspellings [Olivier Thereaux  <ot w3.org>]
 

Modified: httpd/httpd/branches/2.2.x/STATUS
URL: http://svn.apache.org/viewvc/httpd/httpd/branches/2.2.x/STATUS?rev=425725&r1=425724&r2=425725&view=diff
==============================================================================
--- httpd/httpd/branches/2.2.x/STATUS (original)
+++ httpd/httpd/branches/2.2.x/STATUS Wed Jul 26 06:04:27 2006
@@ -82,14 +82,6 @@
        http://issues.apache.org/bugzilla/attachment.cgi?id=18636
        +1: bnicholes, rpluem, fielding
 
-    * mod_cache: Do not overwrite the Content-Type in the cache, for
-      successfully revalidated cached objects. PR 39647.
-        Trunk version of patch:
-          http://svn.apache.org/viewvc?rev=410370&view=rev
-        2.2.x version of patch:
-          Trunk version works
-      +1: rpluem, pquerna, fielding
-
     * mod_authnz_ldap: Fix a problem with invalid auth error detection 
        for LDAP client SDKs that don't support LDAP_SECURITY_ERROR 
        macro. PR#39529

Modified: httpd/httpd/branches/2.2.x/modules/cache/cache_storage.c
URL: http://svn.apache.org/viewvc/httpd/httpd/branches/2.2.x/modules/cache/cache_storage.c?rev=425725&r1=425724&r2=425725&view=diff
==============================================================================
--- httpd/httpd/branches/2.2.x/modules/cache/cache_storage.c (original)
+++ httpd/httpd/branches/2.2.x/modules/cache/cache_storage.c Wed Jul 26 06:04:27 2006
@@ -118,6 +118,17 @@
     if (v) {
         ap_set_content_type(r, v);
         apr_table_unset(h->resp_hdrs, "Content-Type");
+        /*
+         * Also unset possible Content-Type headers in r->headers_out and
+         * r->err_headers_out as they may be different to what we have received
+         * from the cache.
+         * Actually they are not needed as r->content_type set by
+         * ap_set_content_type above will be used in the store_headers functions
+         * of the storage providers as a fallback and the HTTP_HEADER filter
+         * does overwrite the Content-Type header with r->content_type anyway.
+         */
+        apr_table_unset(r->headers_out, "Content-Type");
+        apr_table_unset(r->err_headers_out, "Content-Type");
     }
 
     /* If the cache gave us a Last-Modified header, we can't just



Mime
View raw message