Fix debug.getinfo() argument check.

Thanks to Sergey Ostanevich.
This commit is contained in:
Mike Pall 2019-08-10 00:54:41 +02:00
parent 51e013934b
commit 0cd643d7cf

View File

@ -440,7 +440,7 @@ int lj_debug_getinfo(lua_State *L, const char *what, lj_Debug *ar, int ext)
GCfunc *fn; GCfunc *fn;
if (*what == '>') { if (*what == '>') {
TValue *func = L->top - 1; TValue *func = L->top - 1;
api_check(L, tvisfunc(func)); if (!tvisfunc(func)) return 0;
fn = funcV(func); fn = funcV(func);
L->top--; L->top--;
what++; what++;