diff options
author | ubq323 <ubq323@ubq323.website> | 2023-03-19 20:39:33 +0000 |
---|---|---|
committer | the lemons <citrons@mondecitronne.com> | 2023-03-20 22:24:28 -0500 |
commit | 9ce7a7ed9818208791041a29e6653e16b81d8604 (patch) | |
tree | fefcb2c706cc869d81f4c9de2fc3b387c40057f6 | |
parent | f6a88e1ee6d62dc447a8d8b1d77d63f1ab9b5ade (diff) |
fix stack underflow causing segfault on luajit
-rw-r--r-- | lmdb.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -391,8 +391,9 @@ static void mt(lua_State *L, const char *name, const struct luaL_Reg l[]) { if (lua_isnil(L, -1)){ lua_pop(L, 1); lua_setfield(L, -1, "__index"); + } else { + lua_pop(L, 2); } - lua_pop(L, 2); } static void parentmap(lua_State *L) { |