Module: sems Branch: master Commit: cec50ef7854419010527653800648712366dcd1f URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sems/?a=commit;h=cec50ef7854419010527653800648712366dcd1f
Author: Raphael Coeffic <[email protected]> Committer: Stefan Sayer <[email protected]> Date: Mon Dec 9 11:09:21 2013 +0100 sbc: b/f: correct fix for nat_handling flag support The corresponding code in AmBasicSipDialog::onRxRequest() gets executed before SBCCallLeg::onInvite(), so that we have to fix the next-hop here as well. --- apps/sbc/SBCCallProfile.cpp | 7 ++++--- 1 files changed, 4 insertions(+), 3 deletions(-) diff --git a/apps/sbc/SBCCallProfile.cpp b/apps/sbc/SBCCallProfile.cpp index a563aed..cc79114 100644 --- a/apps/sbc/SBCCallProfile.cpp +++ b/apps/sbc/SBCCallProfile.cpp @@ -888,9 +888,10 @@ int SBCCallProfile::apply_a_routing(ParamReplacerCtx& ctx, } else { dlg.nat_handling = dlg_nat_handling; - if(dlg_nat_handling) { - string nh = req.remote_ip; - nh += ":" + int2str(req.remote_port); + if(dlg_nat_handling && req.first_hop) { + string nh = req.remote_ip + ":" + + int2str(req.remote_port) + + "/" + req.trsp; dlg.setNextHop(nh); dlg.setNextHop1stReq(false); } _______________________________________________ Semsdev mailing list [email protected] http://lists.iptel.org/mailman/listinfo/semsdev
