mirror of
https://github.com/cloudwu/skynet.git
synced 2026-07-24 20:23:06 +00:00
add checksig in OP_FORLOOP, see issue #568
This commit is contained in:
@@ -1201,6 +1201,7 @@ void luaV_execute (lua_State *L) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
vmcase(OP_FORLOOP) {
|
vmcase(OP_FORLOOP) {
|
||||||
|
lua_checksig(L);
|
||||||
if (ttisinteger(ra)) { /* integer loop? */
|
if (ttisinteger(ra)) { /* integer loop? */
|
||||||
lua_Integer step = ivalue(ra + 2);
|
lua_Integer step = ivalue(ra + 2);
|
||||||
lua_Integer idx = intop(+, ivalue(ra), step); /* increment index */
|
lua_Integer idx = intop(+, ivalue(ra), step); /* increment index */
|
||||||
|
|||||||
Reference in New Issue
Block a user