From f441e374518831762ed4a94149045a2f5d1c2257 Mon Sep 17 00:00:00 2001 From: Thomas Ries Date: Sat, 19 Sep 2015 13:21:08 +0000 Subject: [PATCH] --- ChangeLog | 5 +++++ src/proxy.c | 12 +++++------- 2 files changed, 10 insertions(+), 7 deletions(-) diff --git a/ChangeLog b/ChangeLog index 686a4c4..29eca66 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,10 @@ 0.8.2 ===== + xx-Sep-2015: - working on plugin_siptrunk: a plugin to support SIP + trunks with multiple numbers within the same SIP account. + 12-Sep-2015: - added plugin_fix_DTAG: workaround for Deutsche Telekom AG + SIP service which has a broken Via Header handling in some + regions. 17-Jul-2015: - better handling of libltdl bug ("undefined reference to ...") added --with-ltdl-fix to configure) 12-Jul-2015: - better handling of URI params (SNOM: ;line=xxxx in Contact diff --git a/src/proxy.c b/src/proxy.c index 2843eeb..9736f0b 100644 --- a/src/proxy.c +++ b/src/proxy.c @@ -391,13 +391,12 @@ No load balancing and no failover are supported with this. return STS_FAILURE; } + ticket->next_hop.sin_port=SIP_PORT; if (request->req_uri->port) { ticket->next_hop.sin_port=atoi(request->req_uri->port); - if (ticket->next_hop.sin_port != 0) { + if (ticket->next_hop.sin_port == 0) { ticket->next_hop.sin_port=SIP_PORT; } - } else { - ticket->next_hop.sin_port=SIP_PORT; } DEBUGC(DBCLASS_PROXY, "proxy_request: have SIP URI to %s:%i", utils_inet_ntoa(ticket->next_hop.sin_addr), ticket->next_hop.sin_port); @@ -723,13 +722,12 @@ sts=sip_obscure_callid(ticket); return STS_FAILURE; } + ticket->next_hop.sin_port=SIP_PORT; if (via->port) { ticket->next_hop.sin_port=atoi(via->port); - if (ticket->next_hop.sin_port != 0) { - ticket->next_hop.sin_port=SIP_PORT; + if (ticket->next_hop.sin_port == 0) { + ticket->next_hop.sin_port=ticket->next_hop.sin_port; } - } else { - ticket->next_hop.sin_port=SIP_PORT; } }