Module: kamailio
Branch: master
Commit: 14019c67d7fcf8f4d027fa1552ae15cb42d31bdb
URL:
https://github.com/kamailio/kamailio/commit/14019c67d7fcf8f4d027fa1552ae15c…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2021-04-20T12:16:31+02:00
topos: set downstream rr set for replies
---
Modified: src/modules/topos/tps_msg.c
---
Diff:
https://github.com/kamailio/kamailio/commit/14019c67d7fcf8f4d027fa1552ae15c…
Patch:
https://github.com/kamailio/kamailio/commit/14019c67d7fcf8f4d027fa1552ae15c…
---
diff --git a/src/modules/topos/tps_msg.c b/src/modules/topos/tps_msg.c
index 384ae1750e..2389026d14 100644
--- a/src/modules/topos/tps_msg.c
+++ b/src/modules/topos/tps_msg.c
@@ -548,6 +548,14 @@ int tps_pack_message(sip_msg_t *msg, tps_data_t *ptsd)
ptsd->as_contact.len, ZSW(ptsd->as_contact.s), ptsd->as_contact.len,
ptsd->bs_contact.len, ZSW(ptsd->bs_contact.s), ptsd->bs_contact.len);
ptsd->x_rr = ptsd->a_rr;
+ if(isreq==0) {
+ if(msg->first_line.u.reply.statuscode >= 180
+ && msg->first_line.u.reply.statuscode < 199) {
+ /* provisional replies that create early dialogs
+ * - skip 199 Early Dialog Terminated */
+ ptsd->y_rr = ptsd->b_rr;
+ }
+ }
ptsd->s_method_id = get_cseq(msg)->method_id;
if(_tps_context_value.len>0) {
ptsd->x_context = _tps_context_value;