[reSIProcate] findTransportByDest issue
Dear resip devels,
resiprocate 1.9.2,
there is an kludge inside Transportselector::findTransportByDest.
Please consider next piece of code:
std::pair<TypeToTransportMap::iterator, TypeToTransportMap::iterator>
range(mTypeToTransportMap.equal_range(target));
if(range.first != range.second) // At least one match
{
TypeToTransportMap::iterator i=range.first;
++i;
if(i==range.second) // Exactly one match
{
return range.first->second;
}
}
If there is more then 1 TLS transport reigistered - findTransportByDest
always returns 0 - as result TLS does not work.
I think you should add something like
diff --git a/resip/stack/TransportSelector.cxx
b/resip/stack/TransportSelector.cxx
index 62295d5..16b9859 100644
--- a/resip/stack/TransportSelector.cxx
+++ b/resip/stack/TransportSelector.cxx
@@ -1321,6 +1321,7 @@ TransportSelector::findTransportByDest(const
Tuple& target)
{
return range.first->second;
}
+ return i->second;
}
}
Sincerely tez.