]> granicus.if.org Git - apache/commitdiff
Commit 2 of 2 to:
authorBill Stoddard <stoddard@apache.org>
Wed, 20 Mar 2002 17:44:13 +0000 (17:44 +0000)
committerBill Stoddard <stoddard@apache.org>
Wed, 20 Mar 2002 17:44:13 +0000 (17:44 +0000)
1. rename ap_rset_content_type to ap_set_content_type
2. reverse the arguments to aligh with ap_set_content_length

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

include/http_protocol.h
server/core.c
server/util_script.c

index 5e85b11155d0e0f4554820efe1066bf992ffa081..87f823830d80881c92cb9118c4e06a5950b980d0 100644 (file)
@@ -321,9 +321,15 @@ AP_DECLARE(void) ap_method_list_remove(ap_method_list_t *l,
 AP_DECLARE(void) ap_clear_method_list(ap_method_list_t *l);
     
 /**
- *
+ * Set the content type for this request (r->content_type). 
+ * Note:
+ * This function must be called to set r->content_type in order 
+ * for the AddOutputFilterByType directive to work correctly.
+ * @param r The current request
+ * @param length The new content type
+ * @deffunc void ap_set_content_type(request_rec *r, const char* ct)
  */
-AP_DECLARE(void) ap_rset_content_type(const char *str, request_rec *r);
+AP_DECLARE(void) ap_set_content_type(request_rec *r, const char *ct);
 
 /* Hmmm... could macrofy these for now, and maybe forever, though the
  * definitions of the macros would get a whole lot hairier.
index 37be31056d85c8970c05c3989a3a17a463ee65e6..18f54c0db4b3f9cf4d7454c2a4b848399ef3aade 100644 (file)
@@ -3095,7 +3095,7 @@ static int core_override_type(request_rec *r)
     /* Check for overrides with ForceType / SetHandler
      */
     if (conf->mime_type && strcmp(conf->mime_type, "none"))
-        ap_rset_content_type((char*) conf->mime_type, r);
+        ap_set_content_type(r, (char*) conf->mime_type);
 
     if (conf->handler && strcmp(conf->handler, "none"))
         r->handler = conf->handler;
index 36ad107c345b84c35bbb9b330304c7807d6a2e5d..351b08b5a2b9e490ee2f5fa2f40838954e7506d6 100644 (file)
@@ -569,7 +569,7 @@ AP_DECLARE(int) ap_scan_script_header_err_core(request_rec *r, char *buffer,
 
            tmp = apr_pstrdup(r->pool, l);
            ap_content_type_tolower(tmp);
-           ap_rset_content_type(tmp, r);
+           ap_set_content_type(r, tmp);
        }
        /*
         * If the script returned a specific status, that's what