Module: kamailio
Branch: master
Commit: ba365102fe9faa403717eb30f36d363bad13114b
URL:
https://github.com/kamailio/kamailio/commit/ba365102fe9faa403717eb30f36d363…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2023-03-28T17:31:31+02:00
evapi: initialize internal message queue
---
Modified: src/modules/evapi/evapi_dispatch.h
Modified: src/modules/evapi/evapi_mod.c
---
Diff:
https://github.com/kamailio/kamailio/commit/ba365102fe9faa403717eb30f36d363…
Patch:
https://github.com/kamailio/kamailio/commit/ba365102fe9faa403717eb30f36d363…
---
diff --git a/src/modules/evapi/evapi_dispatch.h b/src/modules/evapi/evapi_dispatch.h
index 23b4c2565c..c96bcbf275 100644
--- a/src/modules/evapi/evapi_dispatch.h
+++ b/src/modules/evapi/evapi_dispatch.h
@@ -53,4 +53,6 @@ int pv_set_evapi(sip_msg_t *msg, pv_param_t *param, int op,
int evapi_cfg_close(sip_msg_t *msg);
int evapi_set_tag(sip_msg_t* msg, str* stag);
+int evapi_queue_init(void);
+
#endif
diff --git a/src/modules/evapi/evapi_mod.c b/src/modules/evapi/evapi_mod.c
index 27b3582698..708159ba3a 100644
--- a/src/modules/evapi/evapi_mod.c
+++ b/src/modules/evapi/evapi_mod.c
@@ -163,6 +163,10 @@ static int mod_init(void)
_evapi_bind_addr = _evapi_bind_param;
}
+ if(evapi_queue_init() < 0) {
+ LM_ERR("failed to init faked internal message queue\n");
+ return -1;
+ }
/* add space for one extra process */
register_procs(1 + _evapi_workers);