projects
/
oweals
/
ubus.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
600ec9f
)
lua: fix ubus_lua_format_blob_is_array() to not leave garbage on the stack
author
Jo-Philipp Wich
<jow@openwrt.org>
Tue, 16 Oct 2012 16:37:31 +0000
(19:37 +0300)
committer
Jo-Philipp Wich
<jow@openwrt.org>
Tue, 16 Oct 2012 16:37:31 +0000
(19:37 +0300)
lua/ubus.c
patch
|
blob
|
history
diff --git
a/lua/ubus.c
b/lua/ubus.c
index 081ff45b53f6482657d5922a8bc130f4b294198f..bdf924a03e1b4891d500cced6a1c6b412f2d05aa 100644
(file)
--- a/
lua/ubus.c
+++ b/
lua/ubus.c
@@
-137,7
+137,7
@@
ubus_lua_format_blob_is_array(lua_State *L)
if (lua_type(L, -2) != LUA_TNUMBER)
#endif
{
- lua_pop(L,
1
);
+ lua_pop(L,
2
);
return false;
}
@@
-145,13
+145,14
@@
ubus_lua_format_blob_is_array(lua_State *L)
if ((cur - 1) != prv)
{
- lua_pop(L,
1
);
+ lua_pop(L,
2
);
return false;
}
prv = cur;
}
+ lua_pop(L, 1);
return true;
}