Module: sip-router
Branch: master
Commit: 7b612d999e061d05b60054e7749052d0abdf514c
URL:
http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=7b612d9…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: Thu Nov 17 23:14:32 2011 +0100
tm: free path if set first time in a branch route
---
modules/tm/t_fwd.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/modules/tm/t_fwd.c b/modules/tm/t_fwd.c
index 210601d..26bf7f3 100644
--- a/modules/tm/t_fwd.c
+++ b/modules/tm/t_fwd.c
@@ -374,6 +374,10 @@ static int prepare_new_uac( struct cell *t, struct sip_msg *i_req,
ignored) */
next_hop=&i_req->dst_uri;
}
+ /* no path vector initially, but now is set after branch route and
+ * callbacks execution */
+ if(i_req->path_vec.s!=0 && free_path==0)
+ free_path=1;
}else{
/* no branch route and no TMCB_REQUEST_FWDED callback => set
msg uri and path to the new values (if needed) */