Ref the thread from september,
<http://lists.sip-router.org/pipermail/sr-users/2013-September/079760.html>
I've fixed SRV lookups to work when use_dns_failover is on and the
domain has no _sip._udp record. An example is
cisco.com:
% host -t SRV
_sip._udp.cisco.com
Host
_sip._udp.cisco.com not found: 3(NXDOMAIN)
% host -t SRV
_sip._tcp.cisco.com
_sip._tcp.cisco.com has SRV record 1 0 5060
vcsgw.cisco.com.
% host -t SRV
_sips._tcp.cisco.com
_sips._tcp.cisco.com has SRV record 1 0 5061
vcsgw.cisco.com.
Currently attempting to call an uri at
cisco.com will fail, unless
manually forcing the protocol.
While fixing the the issue I refactored a lot of code and fixed a plenty of
comments as the lookup code has clearly been copy pasted more than once.
Patch is attached and should probably be reviewed thoroughly as it touches
pretty core usage.