Module: kamailio
Branch: 4.4
Commit: 0a274283514a34525daa471cf8e781fb339a870c
URL:
https://github.com/kamailio/kamailio/commit/0a274283514a34525daa471cf8e781f…
Author: grumvalski <federico.cabiddu(a)gmail.com>
Committer: Federico Cabiddu <federico.cabiddu(a)gmail.com>
Date: 2016-07-08T10:56:44+02:00
tm: check branch uri against current uri when deciding if append a new branch
(cherry picked from commit 335e44635aa69ab73ec76f713a7d5ce7ce06748c)
---
Modified: modules/tm/t_append_branches.c
---
Diff:
https://github.com/kamailio/kamailio/commit/0a274283514a34525daa471cf8e781f…
Patch:
https://github.com/kamailio/kamailio/commit/0a274283514a34525daa471cf8e781f…
---
diff --git a/modules/tm/t_append_branches.c b/modules/tm/t_append_branches.c
index f38a0a2..f745e75 100644
--- a/modules/tm/t_append_branches.c
+++ b/modules/tm/t_append_branches.c
@@ -127,7 +127,9 @@ int t_append_branches(void) {
found = 0;
for (i=0; i<outgoings; i++) {
if (t->uac[i].ruid.len == ruid.len
- && !memcmp(t->uac[i].ruid.s, ruid.s, ruid.len)) {
+ && !memcmp(t->uac[i].ruid.s, ruid.s, ruid.len)
+ && t->uac[i].uri.len == current_uri.len
+ && !memcmp(t->uac[i].uri.s, current_uri.s, current_uri.len)) {
LM_DBG("branch already added [%.*s]\n", ruid.len, ruid.s);
found = 1;
break;