From: Bradley Nicholes Date: Fri, 29 Mar 2002 00:39:56 +0000 (+0000) Subject: Stop the while loop from incrementing twice per iteration before checking for X-Git-Tag: 2.0.34~58 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=1f31c48ce12e683015d122e0f47ead6fcd400ee3;p=thirdparty%2Fapache%2Fhttpd.git Stop the while loop from incrementing twice per iteration before checking for the NULL terminator. This was causing the while loop to walk off the end of any string with an odd number of characters. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94276 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/modules/filters/mod_include.c b/modules/filters/mod_include.c index 2e90e18ade0..778e7db33fc 100644 --- a/modules/filters/mod_include.c +++ b/modules/filters/mod_include.c @@ -1179,7 +1179,7 @@ static int is_only_below(const char *path) return 0; #endif path += dots; - while (*path && *(path++) != '/') + while (*path && *(path+1) != '/') ++path; } return 1;