Module: kamailio
Branch: 5.2
Commit: b71938952e1fc7543fa5bf7ba2abed6e39167150
URL:
https://github.com/kamailio/kamailio/commit/b71938952e1fc7543fa5bf7ba2abed6…
Author: Federico Cabiddu <fcabiddu(a)libon.com>
Committer: Federico Cabiddu <fcabiddu(a)libon.com>
Date: 2019-01-17T09:43:29+01:00
siptrace: don't calculate message source socket if already set
(cherry picked from commit 929a24f08aeef6b72999ac9b188ffeded40759a9)
---
Modified: src/modules/siptrace/siptrace.c
---
Diff:
https://github.com/kamailio/kamailio/commit/b71938952e1fc7543fa5bf7ba2abed6…
Patch:
https://github.com/kamailio/kamailio/commit/b71938952e1fc7543fa5bf7ba2abed6…
---
diff --git a/src/modules/siptrace/siptrace.c b/src/modules/siptrace/siptrace.c
index 7de96b4b5d..521ff113ab 100644
--- a/src/modules/siptrace/siptrace.c
+++ b/src/modules/siptrace/siptrace.c
@@ -1492,7 +1492,10 @@ int siptrace_net_data_send(sr_event_param_t *evp)
return -1;
new_dst = *nd->dst;
- new_dst.send_sock = get_send_socket(0, &nd->dst->to, nd->dst->proto);
+
+ if(new_dst.send_sock == 0) {
+ new_dst.send_sock = get_send_socket(0, &nd->dst->to, nd->dst->proto);
+ }
memset(&sto, 0, sizeof(siptrace_data_t));