]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
merge fix to mod_speling crash when r->filename is not set
authorJeff Trawick <trawick@apache.org>
Mon, 13 Mar 2006 16:11:18 +0000 (16:11 +0000)
committerJeff Trawick <trawick@apache.org>
Mon, 13 Mar 2006 16:11:18 +0000 (16:11 +0000)
Reviewed by: jerenkrantz, jim

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/2.2.x@385580 13f79535-47bb-0310-9956-ffa450edef68

CHANGES
STATUS
modules/mappers/mod_speling.c

diff --git a/CHANGES b/CHANGES
index ba0a17c62891c1de1854e2b68be8745e9ef9a36e..9e5fe7219b2a223329e9b2e6e211eb52932fd25a 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -1,6 +1,8 @@
                                                         -*- coding: utf-8 -*-
 Changes with Apache 2.2.1
 
+  *) mod_speling: Stop crashing with certain non-file requests.  [Jeff Trawick]
+
   *) SECURITY: CVE-2005-3357 (cve.mitre.org)
      mod_ssl: Fix a possible crash during access control checks if a
      non-SSL request is processed for an SSL vhost (such as the
diff --git a/STATUS b/STATUS
index 44a339edcc71d82cef7cce6d2bd4c7fe4d2bde7f..e051d141f1c0bfa6a8b96c3fd1167d517fdb69b0 100644 (file)
--- a/STATUS
+++ b/STATUS
@@ -156,11 +156,6 @@ PATCHES PROPOSED TO BACKPORT FROM TRUNK:
         URL: http://people.apache.org/~wrowe/fixldap_mask.patch
       +1: wrowe
 
-    * mod_speling: Don't crash if r->filename unset.
-      Trunk version of patch, which applies fine:
-        http://svn.apache.org/viewcvs?rev=373519&view=rev
-      +1: trawick, jerenkrantz, jim
-
     * core: Fix up botched status lines (mismatch with r->status or
       just badly formatted)
       Trunk version of patch, which applies fine:
index a7b9b9ff1699b045ec70014fca6f567b9b222841..2c427df254ed38f12f284283fd509efad34a1ba2 100644 (file)
@@ -213,7 +213,12 @@ static int check_speling(request_rec *r)
     }
 
     /* We've already got a file of some kind or another */
-    if (r->proxyreq || (r->finfo.filetype != 0)) {
+    if (r->finfo.filetype != 0) {
+        return DECLINED;
+    }
+
+    /* Not a file request */
+    if (r->proxyreq || !r->filename) {
         return DECLINED;
     }