You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by tr...@apache.org on 2014/04/21 23:31:43 UTC

svn commit: r1588989 - /httpd/httpd/trunk/modules/lua/lua_request.c

Author: trawick
Date: Mon Apr 21 21:31:42 2014
New Revision: 1588989

URL: http://svn.apache.org/r1588989
Log:
back to c89

Modified:
    httpd/httpd/trunk/modules/lua/lua_request.c

Modified: httpd/httpd/trunk/modules/lua/lua_request.c
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/modules/lua/lua_request.c?rev=1588989&r1=1588988&r2=1588989&view=diff
==============================================================================
--- httpd/httpd/trunk/modules/lua/lua_request.c (original)
+++ httpd/httpd/trunk/modules/lua/lua_request.c Mon Apr 21 21:31:42 2014
@@ -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);
         }