16 lines
477 B
Text
16 lines
477 B
Text
|
Security fix for CVE-2014-5461,
|
||
|
http://openwall.com/lists/oss-security/2014/08/27/2
|
||
|
|
||
|
Index: src/ldo.c
|
||
|
--- src/ldo.c.orig
|
||
|
+++ src/ldo.c
|
||
|
@@ -274,7 +274,7 @@ int luaD_precall (lua_State *L, StkId func, int nresul
|
||
|
CallInfo *ci;
|
||
|
StkId st, base;
|
||
|
Proto *p = cl->p;
|
||
|
- luaD_checkstack(L, p->maxstacksize);
|
||
|
+ luaD_checkstack(L, p->maxstacksize + p->numparams);
|
||
|
func = restorestack(L, funcr);
|
||
|
if (!p->is_vararg) { /* no varargs? */
|
||
|
base = func + 1;
|