]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
back to c89
authorJeff Trawick <trawick@apache.org>
Mon, 21 Apr 2014 21:31:42 +0000 (21:31 +0000)
committerJeff Trawick <trawick@apache.org>
Mon, 21 Apr 2014 21:31:42 +0000 (21:31 +0000)
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1588989 13f79535-47bb-0310-9956-ffa450edef68

modules/lua/lua_request.c

index 272936ecb3cbb89df0ae6d00844bcb950a31c37d..445e3caf1f9af99f34084b8aaa8ff1ecdc4ebdf3 100644 (file)
@@ -320,10 +320,11 @@ static int req_parseargs(lua_State *L)
 /* ap_lua_binstrstr: Binary strstr function for uploaded data with NULL bytes */
 static char* ap_lua_binstrstr (const char * haystack, size_t hsize, const char* needle, size_t nsize)
 {
+    size_t p;
     if (haystack == NULL) return NULL;
     if (needle == NULL) return NULL;
     if (hsize < nsize) return NULL;
-    for (size_t p = 0; p <= (hsize - nsize); ++p) {
+    for (p = 0; p <= (hsize - nsize); ++p) {
         if (memcmp(haystack + p, needle, nsize) == 0) {
             return (char*) (haystack + p);
         }