Adjust for __libc_res_nsearch interface change.
authordrepper <drepper>
Mon, 28 Jul 2008 22:53:35 +0000 (22:53 +0000)
committerdrepper <drepper>
Mon, 28 Jul 2008 22:53:35 +0000 (22:53 +0000)
commit042c6b69217ee775514fcb4ae57b86defa334c43
treec4fce6adff1bf41dab364414144bda0ba1443473
parent0f05063cbbb120f64ad980023c34217d198f97df
Adjust for __libc_res_nsearch interface change.
(_nss_dns_gethostbyname4): Don't unconditionally allocate tmp array.
Define resplen2 variable and pass it to __libc_res_nsearch and then
to gaih_getanswer.
(getanswer_r): In case of incorrect DNS data don't overread buffer.
Add branch prediction.
(gaih_getanswer_slice): Likewise.  Check for invalid data types.
(gaih_getanswer): Don't decode second slice if first one failed due
to a too small buffer.  Don't let not found status of second
decoder shadow results of the first.
resolv/nss_dns/dns-host.c