forked from Mirrorlandia_minetest/minetest
Check for table type when reading groups from Lua
This commit is contained in:
parent
38580fbee7
commit
369046bbb4
@ -686,6 +686,8 @@ static NodeBox read_nodebox(lua_State *L, int index)
|
|||||||
static void read_groups(lua_State *L, int index,
|
static void read_groups(lua_State *L, int index,
|
||||||
std::map<std::string, int> &result)
|
std::map<std::string, int> &result)
|
||||||
{
|
{
|
||||||
|
if (!lua_istable(L,index))
|
||||||
|
return;
|
||||||
result.clear();
|
result.clear();
|
||||||
lua_pushnil(L);
|
lua_pushnil(L);
|
||||||
if(index < 0)
|
if(index < 0)
|
||||||
|
Loading…
Reference in New Issue
Block a user