From: kwolekr Date: Thu, 30 Oct 2014 20:23:48 +0000 (-0400) Subject: Fix erroneous lua_pop parameter X-Git-Tag: 0.4.11~200 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=db25f753375a97c71609ec4e2a3f7f6983904a54;p=oweals%2Fminetest.git Fix erroneous lua_pop parameter --- diff --git a/src/script/lua_api/l_mapgen.cpp b/src/script/lua_api/l_mapgen.cpp index 75f5afa88..fdbeafb31 100644 --- a/src/script/lua_api/l_mapgen.cpp +++ b/src/script/lua_api/l_mapgen.cpp @@ -475,9 +475,11 @@ bool ModApiMapgen::regDecoSchematic(lua_State *L, lua_pop(L, 1); lua_getfield(L, index, "schematic"); - if (!read_schematic(L, -1, deco, getServer(L))) + if (!read_schematic(L, -1, deco, getServer(L))) { + lua_pop(L, 1); return false; - lua_pop(L, -1); + } + lua_pop(L, 1); if (!deco->filename.empty() && !deco->loadSchematicFile(resolver, replace_names)) {