From 829a8a6e82c8c3e2dfc678b82aa1b488ba371aed Mon Sep 17 00:00:00 2001 From: Daniel-Constantin Mierla Date: Sun, 24 Apr 2016 09:32:27 +0200 Subject: [PATCH] app_lua: exported special kemi function to execute module function - KSR.x.modf(fname, params...) --- modules/app_lua/app_lua_sr.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/modules/app_lua/app_lua_sr.c b/modules/app_lua/app_lua_sr.c index a869c52f327..0530fdede3b 100644 --- a/modules/app_lua/app_lua_sr.c +++ b/modules/app_lua/app_lua_sr.c @@ -1684,6 +1684,14 @@ int sr_kemi_exec_func(lua_State* L, str *mname, int midx, str *fname) return app_lua_return_false(L); } +/** + * + */ +static const luaL_Reg _sr_kemi_x_Map [] = { + {"modf", lua_sr_modf}, + {NULL, NULL} +}; + /** * */ @@ -1747,6 +1755,7 @@ void lua_sr_kemi_register_core(lua_State *L) /* special modules - pv.get(...) can return int or str */ luaL_openlib(L, "KSR.pv", _sr_pv_Map, 0); + luaL_openlib(L, "KSR.x", _sr_kemi_x_Map, 0); LM_DBG("pushing lua KSR table definition returned %d\n", ret); }