projects
/
project
/
ubus.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1d2b3bb
)
lua: fix stack leak in ubus method handling
author
Felix Fietkau
<nbd@openwrt.org>
Wed, 20 Jan 2016 13:59:04 +0000
(14:59 +0100)
committer
Felix Fietkau
<nbd@openwrt.org>
Wed, 20 Jan 2016 13:59:06 +0000
(14:59 +0100)
Signed-off-by: Chen Bin <ewolfok@126.com>
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
lua/ubus.c
patch
|
blob
|
history
diff --git
a/lua/ubus.c
b/lua/ubus.c
index 2903e7b1ea7142e5e8ff7f919875e04d16a859e9..86e34b7c0739f6c568925bfb5feeb4d34ca0d570 100644
(file)
--- a/
lua/ubus.c
+++ b/
lua/ubus.c
@@
-302,8
+302,9
@@
ubus_method_handler(struct ubus_context *ctx, struct ubus_object *obj,
lua_call(state, 2, 1);
if (lua_isnumber(state, -1))
rv = lua_tonumber(state, -1);
- } else
- lua_pop(state, 1);
+ }
+
+ lua_pop(state, 1);
return rv;
}