]> granicus.if.org Git - apache/commitdiff
Change ap_gm_timestr_822 to ap_timestr. Now, one function can be used to get
authorRyan Bloom <rbb@apache.org>
Tue, 21 Dec 1999 16:21:44 +0000 (16:21 +0000)
committerRyan Bloom <rbb@apache.org>
Tue, 21 Dec 1999 16:21:44 +0000 (16:21 +0000)
a timestr for GMT and Localtimes.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@84352 13f79535-47bb-0310-9956-ffa450edef68

modules/http/http_protocol.c

index e111ce3ca5e0c89138b41a3c66972c7d8cc3679c..eef96c310fe56cc4c867a5f168748cc685231d72 100644 (file)
@@ -605,7 +605,7 @@ API_EXPORT(void) ap_set_last_modified(request_rec *r)
 {
     ap_time_t *mod_time = ap_rationalize_mtime(r, r->mtime);
     char *datestr;
-    ap_gm_timestr_822(&datestr, mod_time, r->pool);
+    ap_timestr(&datestr, mod_time, APR_UTCTIME, r->pool);
     ap_table_setn(r->headers_out, "Last-Modified", datestr);
 }
 
@@ -1362,7 +1362,7 @@ API_EXPORT(void) ap_basic_http_header(request_rec *r)
 
     ap_rvputs(r, protocol, " ", r->status_line, "\015\012", NULL);
 
-    ap_gm_timestr_822(&date, r->request_time, r->pool);
+    ap_timestr(&date, r->request_time, APR_UTCTIME, r->pool);
     ap_send_header_field(r, "Date", date);
     ap_send_header_field(r, "Server", ap_get_server_version());
 
@@ -1645,7 +1645,7 @@ API_EXPORT(void) ap_send_http_header(request_rec *r)
      * some other part of the server configuration.
      */
     if (r->no_cache && !ap_table_get(r->headers_out, "Expires")) {
-        ap_gm_timestr_822(&date, r->request_time, r->pool);
+        ap_timestr(&date, r->request_time, APR_UTCTIME, r->pool);
         ap_table_addn(r->headers_out, "Expires", date);
     }