luaa: pop pushed value

Signed-off-by: Julien Danjou <julien@danjou.info>
This commit is contained in:
Julien Danjou 2009-04-03 11:24:03 +02:00
parent 4605bf5d55
commit c036c8d234
1 changed files with 4 additions and 2 deletions

6
luaa.c
View File

@ -599,14 +599,16 @@ luaA_isloop(lua_State *L, int idx)
/* elems is an elements array that we will fill with all array we /* elems is an elements array that we will fill with all array we
* encounter while browsing the tables */ * encounter while browsing the tables */
void_array_t elems; void_array_t elems;
bool ret = false;
void_array_init(&elems); void_array_init(&elems);
/* push table on top */ /* push table on top */
lua_pushvalue(L, idx); lua_pushvalue(L, idx);
ret = luaA_isloop_check(L, &elems); bool ret = luaA_isloop_check(L, &elems);
/* remove pushed table */
lua_pop(L, 1);
void_array_wipe(&elems); void_array_wipe(&elems);