1
0
mirror of https://github.com/nmap/nmap.git synced 2026-01-08 07:29:03 +00:00

Don't strdup (and fail to free) pattern passed to pcre_compile.

http://seclists.org/nmap-dev/2012/q2/627
This commit is contained in:
david
2012-06-05 21:09:01 +00:00
parent 7f0c9fa9a2
commit 86077ed05f

View File

@@ -109,7 +109,7 @@ static int Lpcre_comp(lua_State *L)
const char *error;
int erroffset;
pcre2 *ud;
char *pattern = strdup(luaL_checkstring(L, 1));
const char *pattern = luaL_checkstring(L, 1);
int cflags = luaL_optint(L, 2, 0);
const unsigned char *tables = NULL;