Skip to content

Commit 03dc368

Browse files
committed
fix bug in lua table copying
1 parent 8bf0b2e commit 03dc368

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/script.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -492,8 +492,8 @@ void script_copy_value(lua_State *src, lua_State *dst, int index) {
492492
lua_newtable(dst);
493493
lua_pushnil(src);
494494
while (lua_next(src, index - 1)) {
495-
script_copy_value(src, dst, -1);
496495
script_copy_value(src, dst, -2);
496+
script_copy_value(src, dst, -1);
497497
lua_settable(dst, -3);
498498
lua_pop(src, 1);
499499
}

0 commit comments

Comments
 (0)