httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bri...@apache.org
Subject cvs commit: httpd-2.0/server protocol.c
Date Tue, 18 Dec 2001 23:57:36 GMT
brianp      01/12/18 15:57:36

  Modified:    server   protocol.c
  Log:
  Skip the setting of Last-Modified in the response header on
  requests or subrequests for which no response header will be
  generated (a performance improvement for mod_include)
  
  Revision  Changes    Path
  1.62      +6 -4      httpd-2.0/server/protocol.c
  
  Index: protocol.c
  ===================================================================
  RCS file: /home/cvs/httpd-2.0/server/protocol.c,v
  retrieving revision 1.61
  retrieving revision 1.62
  diff -u -r1.61 -r1.62
  --- protocol.c	2001/12/13 16:41:43	1.61
  +++ protocol.c	2001/12/18 23:57:36	1.62
  @@ -1267,10 +1267,12 @@
    */
   AP_DECLARE(void) ap_set_last_modified(request_rec *r)
   {
  -    apr_time_t mod_time = ap_rationalize_mtime(r, r->mtime);
  -    char *datestr = apr_palloc(r->pool, APR_RFC822_DATE_LEN);
  -    apr_rfc822_date(datestr, mod_time);
  -    apr_table_setn(r->headers_out, "Last-Modified", datestr);
  +    if (!r->assbackwards) {
  +        apr_time_t mod_time = ap_rationalize_mtime(r, r->mtime);
  +        char *datestr = apr_palloc(r->pool, APR_RFC822_DATE_LEN);
  +        apr_rfc822_date(datestr, mod_time);
  +        apr_table_setn(r->headers_out, "Last-Modified", datestr);
  +    }
   }
   
   AP_IMPLEMENT_HOOK_RUN_ALL(int,post_read_request,
  
  
  

Mime
View raw message