Module: kamailio
Branch: 5.2
Commit: a7f6227efe8228444a8afd17e548640ca8458beb
URL:
https://github.com/kamailio/kamailio/commit/a7f6227efe8228444a8afd17e548640…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2019-03-28T19:38:07+01:00
app_lua: get lua execution stack for previous level
- returns the info where current function was executed
(cherry picked from commit a15210d064e08ac8b1a271502360b7066bff43b6)
---
Modified: src/modules/app_lua/app_lua_sr.c
---
Diff:
https://github.com/kamailio/kamailio/commit/a7f6227efe8228444a8afd17e548640…
Patch:
https://github.com/kamailio/kamailio/commit/a7f6227efe8228444a8afd17e548640…
---
diff --git a/src/modules/app_lua/app_lua_sr.c b/src/modules/app_lua/app_lua_sr.c
index 7b1322ee21..d223975f04 100644
--- a/src/modules/app_lua/app_lua_sr.c
+++ b/src/modules/app_lua/app_lua_sr.c
@@ -1942,7 +1942,7 @@ int sr_kemi_lua_exec_func(lua_State* L, int eidx)
+ (tve.tv_usec - tvb.tv_usec);
if(tdiff >= cfg_get(core, core_cfg, latency_limit_action)) {
memset(&dinfo, 0, sizeof(lua_Debug));
- if(lua_getstack(L, 0, &dinfo)>0
+ if(lua_getstack(L, 1, &dinfo)>0
&& lua_getinfo(L, "nSl", &dinfo)>0) {
LOG(cfg_get(core, core_cfg, latency_log),
"alert - action KSR.%s%s%s(...)"