Return-Path: Delivered-To: apmail-httpd-cvs-archive@httpd.apache.org Received: (qmail 24117 invoked by uid 500); 11 Dec 2002 21:53:23 -0000 Mailing-List: contact cvs-help@httpd.apache.org; run by ezmlm Precedence: bulk Reply-To: dev@httpd.apache.org list-help: list-unsubscribe: list-post: Delivered-To: mailing list cvs@httpd.apache.org Received: (qmail 24091 invoked by uid 500); 11 Dec 2002 21:53:23 -0000 Delivered-To: apmail-httpd-2.0-cvs@apache.org Date: 11 Dec 2002 21:53:22 -0000 Message-ID: <20021211215322.2222.qmail@icarus.apache.org> From: stoddard@apache.org To: httpd-2.0-cvs@apache.org Subject: cvs commit: httpd-2.0/modules/experimental mod_cache.c X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N stoddard 2002/12/11 13:53:22 Modified: modules/experimental mod_cache.c Log: Don't spend cycles finding cache-control until we actually need it. Revision Changes Path 1.68 +3 -2 httpd-2.0/modules/experimental/mod_cache.c Index: mod_cache.c =================================================================== RCS file: /home/cvs/httpd-2.0/modules/experimental/mod_cache.c,v retrieving revision 1.67 retrieving revision 1.68 diff -u -r1.67 -r1.68 --- mod_cache.c 3 Dec 2002 23:08:22 -0000 1.67 +++ mod_cache.c 11 Dec 2002 21:53:22 -0000 1.68 @@ -419,7 +419,7 @@ int rv; request_rec *r = f->r; char *url = r->unparsed_uri; - const char *cc_out = apr_table_get(r->headers_out, "Cache-Control"); + const char *cc_out; const char *exps, *lastmods, *dates, *etag; apr_time_t exp, date, lastmod, now; apr_off_t size; @@ -516,8 +516,9 @@ lastmod = APR_DATE_BAD; } - /* read the etag from the entity */ + /* read the etag and cache-control from the entity */ etag = apr_table_get(r->headers_out, "Etag"); + cc_out = apr_table_get(r->headers_out, "Cache-Control"); /* * what responses should we not cache?