]> granicus.if.org Git - apache/commitdiff
Move ap_set_last_modified to the core. This is a potentially
authorRyan Bloom <rbb@apache.org>
Sun, 25 Mar 2001 20:42:47 +0000 (20:42 +0000)
committerRyan Bloom <rbb@apache.org>
Sun, 25 Mar 2001 20:42:47 +0000 (20:42 +0000)
controversial change, because this is kind of HTTP specific.  However
many protocols should be able to take advantage of this kind of
information.  I expect that headers will need one more layer of
indirection for multi-protocol work, but this is a small step in
the right direction.

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

CHANGES
modules/http/http_protocol.c
server/protocol.c

diff --git a/CHANGES b/CHANGES
index ba1932864afbf5d86f8e5f6567965f65d24f15f5..a0dbc839683e87b49c6eea9bf7a08a30fd8a54b6 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -1,5 +1,12 @@
 Changes with Apache 2.0.16-dev
 
+  *) Move ap_set_last_modified to the core.  This is a potentially 
+     controversial change, because this is kind of HTTP specific.  However
+     many protocols should be able to take advantage of this kind of
+     information.  I expect that headers will need one more layer of
+     indirection for multi-protocol work, but this is a small step in
+     the right direction.  [Ryan Bloom]
+
   *) Enable mod_status by default.  This matches what Apache 1.3 does.
      [Ed Korthof]
 
index 82e4603a79d0a2e86d8fbef24933fd623d15809c..f6c75b83a75e99723646365810a7590287fd0512 100644 (file)
@@ -299,19 +299,6 @@ AP_DECLARE(int) ap_meets_conditions(request_rec *r)
     return OK;
 }
 
-/*
- * This function sets the Last-Modified output header field to the value
- * of the mtime field in the request structure - rationalized to keep it from
- * being in the future.
- */
-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);
-}
-
 /* Get the method number associated with the given string, assumed to
  * contain an HTTP method.  Returns M_INVALID if not recognized.
  *
index 6f078be14d6724ba1dcf131b4b245f77f6f98264..b32f651a86dcbb8462591825c684c7c5ac07e21a 100644 (file)
@@ -1544,6 +1544,19 @@ AP_DECLARE(int) ap_rflush(request_rec *r)
     return 0;
 }
 
+/*
+ * This function sets the Last-Modified output header field to the value
+ * of the mtime field in the request structure - rationalized to keep it from
+ * being in the future.
+ */
+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);
+}
+
 AP_IMPLEMENT_HOOK_RUN_ALL(int,post_read_request,
                           (request_rec *r),(r),OK,DECLINED)
 AP_IMPLEMENT_HOOK_RUN_ALL(int,log_transaction,