Module: kamailio
Branch: master
Commit: 10b6bc16de2047edd6dfd83fe40718b801e538d2
URL:
https://github.com/kamailio/kamailio/commit/10b6bc16de2047edd6dfd83fe40718b…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2018-12-12T10:43:00+01:00
app_sqlang: support executing kemi functions with (str*, str*, int, int, str*) params
---
Modified: src/modules/app_sqlang/app_sqlang_api.c
---
Diff:
https://github.com/kamailio/kamailio/commit/10b6bc16de2047edd6dfd83fe40718b…
Patch:
https://github.com/kamailio/kamailio/commit/10b6bc16de2047edd6dfd83fe40718b…
---
diff --git a/src/modules/app_sqlang/app_sqlang_api.c
b/src/modules/app_sqlang/app_sqlang_api.c
index 302e78a3b3..79465940fd 100644
--- a/src/modules/app_sqlang/app_sqlang_api.c
+++ b/src/modules/app_sqlang/app_sqlang_api.c
@@ -1412,6 +1412,15 @@ int sr_kemi_sqlang_exec_func_ex(HSQUIRRELVM J, sr_kemi_t *ket)
&vps[0].s, &vps[1].s, &vps[2].s, &vps[3].s,
&vps[4].s);
return sr_kemi_sqlang_return_int(J, ket, ret);
+ } else if(ket->ptypes[0]==SR_KEMIP_STR
+ && ket->ptypes[1]==SR_KEMIP_STR
+ && ket->ptypes[2]==SR_KEMIP_INT
+ && ket->ptypes[3]==SR_KEMIP_INT
+ && ket->ptypes[4]==SR_KEMIP_STR) {
+ ret = ((sr_kemi_fmssnns_f)(ket->func))(env_J->msg,
+ &vps[0].s, &vps[1].s, vps[2].n, vps[3].n,
+ &vps[4].s);
+ return sr_kemi_sqlang_return_int(J, ket, ret);
} else {
LM_ERR("invalid parameters for: %.*s\n",
fname->len, fname->s);