Module: kamailio
Branch: master
Commit: 5b0e74c1832d2d09fe36424e1e1aaaacde920b31
URL:
https://github.com/kamailio/kamailio/commit/5b0e74c1832d2d09fe36424e1e1aaaa…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2021-05-31T17:23:42+02:00
async: safety check for async ms list
---
Modified: src/modules/async/async_sleep.c
---
Diff:
https://github.com/kamailio/kamailio/commit/5b0e74c1832d2d09fe36424e1e1aaaa…
Patch:
https://github.com/kamailio/kamailio/commit/5b0e74c1832d2d09fe36424e1e1aaaa…
---
diff --git a/src/modules/async/async_sleep.c b/src/modules/async/async_sleep.c
index 1e81d3318c..bd17b0e1d9 100644
--- a/src/modules/async/async_sleep.c
+++ b/src/modules/async/async_sleep.c
@@ -370,6 +370,10 @@ int async_ms_sleep(sip_msg_t *msg, int milliseconds, cfg_action_t
*act, str *cbn
async_task_param_t *atp;
async_task_t *at;
+ if (_async_ms_list==NULL) {
+ LM_ERR("async timer list not initialized - check modparams\n");
+ return -1;
+ }
if(milliseconds <= 0) {
LM_ERR("negative or zero sleep time (%d)\n", milliseconds);
return -1;