You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by ni...@apache.org on 2008/09/08 17:53:00 UTC
svn commit: r693141 - in /httpd/httpd/trunk: CHANGES modules/http/mod_mime.c
Author: niq
Date: Mon Sep 8 08:52:59 2008
New Revision: 693141
URL: http://svn.apache.org/viewvc?rev=693141&view=rev
Log:
mod_mime: don't adjust case in filename components we don't use
PR 43250, patch by Basant Kumar Kukreja
Modified:
httpd/httpd/trunk/CHANGES
httpd/httpd/trunk/modules/http/mod_mime.c
Modified: httpd/httpd/trunk/CHANGES
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/CHANGES?rev=693141&r1=693140&r2=693141&view=diff
==============================================================================
--- httpd/httpd/trunk/CHANGES [utf-8] (original)
+++ httpd/httpd/trunk/CHANGES [utf-8] Mon Sep 8 08:52:59 2008
@@ -2,6 +2,10 @@
Changes with Apache 2.3.0
[ When backported to 2.2.x, remove entry from this file ]
+ *) Don't adjust case in pathname components that are not of interest
+ to mod_mime. Fixes mod_negotiation's use of such components.
+ PR 43250 [Basant Kumar Kukreja <basant.kukreja sun.com>]
+
*) Add new LogFormat parameter, %k, which logs the number of
keepalive requests on this connection for this request..
[Dan Poirier <poirier pobox.com>]
Modified: httpd/httpd/trunk/modules/http/mod_mime.c
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/modules/http/mod_mime.c?rev=693141&r1=693140&r2=693141&view=diff
==============================================================================
--- httpd/httpd/trunk/modules/http/mod_mime.c (original)
+++ httpd/httpd/trunk/modules/http/mod_mime.c Mon Sep 8 08:52:59 2008
@@ -785,6 +785,7 @@
while (*fn && (ext = ap_getword(r->pool, &fn, '.'))) {
const extension_info *exinfo = NULL;
int found;
+ char *extcase;
if (*ext == '\0') { /* ignore empty extensions "bad..html" */
continue;
@@ -792,6 +793,9 @@
found = 0;
+ /* Save the ext in extcase before converting it to lower case.
+ */
+ extcase = apr_pstrdup(r->pool, ext);
ap_str_tolower(ext);
if (conf->extension_mappings != NULL) {
@@ -885,7 +889,7 @@
found_metadata = 1;
}
else {
- *((const char **) apr_array_push(exception_list)) = ext;
+ *((const char **) apr_array_push(exception_list)) = extcase;
}
}