[asterisk-dev] [Code Review] Add getnameinfo() to ast_sockaddr_resolve()

Simon Perreault simon.perreault at viagenie.ca
Tue May 3 15:17:24 CDT 2011


Let's continue this by email if you don't mind...

On 2011-05-03 15:57, Paul Belanger wrote:
> Sure, at first pass getaddrinfo() would return success for SIP/1050.
> But SIP/1050 is not a peer, so Asterisk assume it is a hostname.
> 
> [Dec 20 23:45:29] DEBUG[2288] netsock2.c: Splitting '1050' gives...

Stop right here. getaddrinfo("1050", ...) should fail. Are you sure it
doesn't fail? And if it doesn't fail then it means it resolved to
something, so why don't we just use that something and be happy?

Simon
-- 
DTN made easy, lean, and smart --> http://postellation.viagenie.ca
NAT64/DNS64 open-source        --> http://ecdysis.viagenie.ca
STUN/TURN server               --> http://numb.viagenie.ca



More information about the asterisk-dev mailing list