[sr-dev] git:5.1:0a327ed6: tm: make t_run_local_req reentrant

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[sr-dev] git:5.1:0a327ed6: tm: make t_run_local_req reentrant

Federico Cabiddu-2
Module: kamailio
Branch: 5.1
Commit: 0a327ed62b47bd56b7b7463c2552d2c66397e897
URL: https://github.com/kamailio/kamailio/commit/0a327ed62b47bd56b7b7463c2552d2c66397e897

Author: grumvalski <[hidden email]>
Committer: Federico Cabiddu <[hidden email]>
Date: 2017-12-06T17:26:45+01:00

tm: make t_run_local_req reentrant

- avoid crash when local-request event route is triggered inside another one

(cherry picked from commit 97b15611ad87e36dd17ba76a77cb8817d974806b)

---

Modified: src/modules/tm/uac.c

---

Diff:  https://github.com/kamailio/kamailio/commit/0a327ed62b47bd56b7b7463c2552d2c66397e897.diff
Patch: https://github.com/kamailio/kamailio/commit/0a327ed62b47bd56b7b7463c2552d2c66397e897.patch

---

diff --git a/src/modules/tm/uac.c b/src/modules/tm/uac.c
index dddeb0aa34..7b78a609b3 100644
--- a/src/modules/tm/uac.c
+++ b/src/modules/tm/uac.c
@@ -221,7 +221,7 @@ static inline int t_run_local_req(
  uac_req_t *uac_r,
  struct cell *new_cell, struct retr_buf *request)
 {
- static struct sip_msg lreq;
+ struct sip_msg lreq = {0};
  struct onsend_info onsnd_info;
  tm_xlinks_t backup_xd;
  int sflag_bk;


_______________________________________________
Kamailio (SER) - Development Mailing List
[hidden email]
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev