Module: kamailio Branch: master Commit: 403de77c079a125ac101ff2ae58e08551a12a022 URL: https://github.com/kamailio/kamailio/commit/403de77c079a125ac101ff2ae58e0855...
Author: Daniel-Constantin Mierla miconda@gmail.com Committer: Daniel-Constantin Mierla miconda@gmail.com Date: 2019-05-13T10:03:43+02:00
core: proper check for allocation of route_locks_size
- regression added with relocation of code
---
Modified: src/core/receive.c
---
Diff: https://github.com/kamailio/kamailio/commit/403de77c079a125ac101ff2ae58e0855... Patch: https://github.com/kamailio/kamailio/commit/403de77c079a125ac101ff2ae58e0855...
---
diff --git a/src/core/receive.c b/src/core/receive.c index 3a2919cec2..8034ae9618 100644 --- a/src/core/receive.c +++ b/src/core/receive.c @@ -48,6 +48,7 @@ #include "usr_avp.h" #include "xavp.h" #include "select_buf.h" +#include "locking.h"
#include "tcp_server.h" /* for tcpconn_add_alias */ #include "tcp_options.h" /* for access to tcp_accept_aliases*/ @@ -77,7 +78,7 @@ int ksr_route_locks_set_init(void) return 0;
ksr_route_locks_set = rec_lock_set_alloc(ksr_route_locks_size); - if(ksr_route_locks_set) { + if(ksr_route_locks_set==NULL) { LM_ERR("failed to allocate route locks set\n"); return -1; }