mirror of
https://github.com/mlua-rs/mlua
synced 2026-06-08 16:05:43 +00:00
Grow/check Lua stack in unpack
This commit is contained in:
@@ -2402,6 +2402,7 @@ impl Lua {
|
||||
|
||||
unsafe extern "C" fn unpack(state: *mut ffi::lua_State) -> c_int {
|
||||
let len = ffi::lua_tointeger(state, 2);
|
||||
ffi::luaL_checkstack(state, len as c_int, ptr::null());
|
||||
for i in 1..=len {
|
||||
ffi::lua_rawgeti(state, 1, i);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user