]> granicus.if.org Git - apache/commitdiff
Centralize hop-by-hop header handling in the memory caching code.
authorDirk-Willem van Gulik <dirkx@apache.org>
Thu, 17 Apr 2008 16:38:36 +0000 (16:38 +0000)
committerDirk-Willem van Gulik <dirkx@apache.org>
Thu, 17 Apr 2008 16:38:36 +0000 (16:38 +0000)
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@649178 13f79535-47bb-0310-9956-ffa450edef68

modules/cache/mod_mem_cache.c

index 1c6d60243937daccadd8026faf696b96ff1fbbad..d3e9648af54e02139fcf38453070aeb3c61a91e0 100644 (file)
@@ -604,17 +604,8 @@ static apr_status_t store_headers(cache_handle_t *h, request_rec *r, cache_info
     mobj->req_hdrs = deep_table_copy(mobj->pool, r->headers_in);
 
     /* Precompute how much storage we need to hold the headers */
-    headers_out = ap_cache_cacheable_hdrs_out(r->pool, r->headers_out,
-                                              r->server);
+    headers_out = ap_cache_cacheable_headers_out(r);
 
-    /* If not set in headers_out, set Content-Type */
-    if (!apr_table_get(headers_out, "Content-Type")
-        && r->content_type) {
-        apr_table_setn(headers_out, "Content-Type",
-                       ap_make_content_type(r, r->content_type));
-    }
-
-    headers_out = apr_table_overlay(r->pool, headers_out, r->err_headers_out);
     mobj->header_out = deep_table_copy(mobj->pool, headers_out);
 
     /* Init the info struct */