]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
The original answer was evil, return NULL if the file name has no path!
authorWilliam A. Rowe Jr <wrowe@apache.org>
Mon, 23 Jul 2001 19:52:41 +0000 (19:52 +0000)
committerWilliam A. Rowe Jr <wrowe@apache.org>
Mon, 23 Jul 2001 19:52:41 +0000 (19:52 +0000)
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@89666 13f79535-47bb-0310-9956-ffa450edef68

server/util.c

index 7ff05caa6e692864f4bf612edb48c3ad305a7a62..8d529b054bb05288f3e39d9bdd152906444303f9 100644 (file)
@@ -599,8 +599,7 @@ AP_DECLARE(char *) ap_make_dirstr_parent(apr_pool_t *p, const char *s)
     int l;
 
     if (last_slash == NULL) {
-       /* XXX: well this is really broken if this happens */
-       return (apr_pstrdup(p, "/"));
+       return NULL;
     }
     l = (last_slash - s) + 1;
     d = apr_palloc(p, l + 1);