X-Git-Url: https://git.archive.openwrt.org/?p=project%2Fubus.git;a=blobdiff_plain;f=lua%2Fubus.c;h=00d9e002a19095247546a992df67c190f47d6998;hp=cfe9c9b0abde93feb9447f334aced7d1c96d91b1;hb=HEAD;hpb=212ceb1b021bc0db19201894e1e9633fa6a25638 diff --git a/lua/ubus.c b/lua/ubus.c index cfe9c9b..00d9e00 100644 --- a/lua/ubus.c +++ b/lua/ubus.c @@ -787,10 +787,11 @@ ubus_sub_notify_handler(struct ubus_context *ctx, struct ubus_object *obj, if (lua_isfunction(state, -1)) { if( msg ){ ubus_lua_parse_blob_array(state, blob_data(msg), blob_len(msg), true); - lua_call(state, 1, 0); } else { - lua_call(state, 0, 0); + lua_pushnil(state); } + lua_pushstring(state, method); + lua_call(state, 2, 0); } else { lua_pop(state, 1); }