dns: Use ntohl for ans->ttl in dns_parse_answer_ex
authorGeorge Joseph <george.joseph@fairview5.com>
Fri, 6 Nov 2015 20:19:11 +0000 (13:19 -0700)
committerGeorge Joseph <george.joseph@fairview5.com>
Fri, 6 Nov 2015 20:19:11 +0000 (13:19 -0700)
commitd82a4b098f41efe921b02440450e58320905360a
treec5ef48659b55a44c68570a47e491faad9ce58204
parentf12ebe35848c2ce82e53b332742e83b2b5875502
dns: Use ntohl for ans->ttl in dns_parse_answer_ex

dns_parse_answer_ex was not converting ans->ttl from network
by order to host byte order which was causing certain ttls
it to go negative. In turn this was causing answer edit checks
to fail.

ASTERISK-25528 #close
Reported-by: Daniel Tryba
Tested-by: George Joseph

Change-Id: I31505132d6321c46d2f39fd06c20ee808a864037
main/dns.c