Module: sip-router Branch: 3.2 Commit: 609b0aa86624416828c0c117e0cfdbeb7643bcb8 URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=609b0aa8...
Author: Daniel-Constantin Mierla miconda@gmail.com Committer: Daniel-Constantin Mierla miconda@gmail.com Date: Thu Nov 17 23:14:32 2011 +0100
tm: free path if set first time in a branch route (cherry picked from commit 7b612d999e061d05b60054e7749052d0abdf514c)
---
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) */