bionic/libc/dns
Robert Alm 3638a83657 Add error-check when mapping socket to fd
The call to fdopen can fail in several ways.
The fprintf on the next line will then dereference a
NULL-pointer FILE*.
Added a NULL-check, closed the socket, returned system error
and added a comment about it.

Change-Id: I7a6b26aa3c79452b1fdd76af12dfa75da88cbad7
2014-11-27 11:01:50 -08:00
..
include am 72d72d91: Merge "Replace uses of sprintf(3) with snprintf(3)." 2014-10-09 00:13:06 +00:00
nameser Replace uses of sprintf(3) with snprintf(3). 2014-10-08 16:12:27 -07:00
net Add error-check when mapping socket to fd 2014-11-27 11:01:50 -08:00
resolv am 72d72d91: Merge "Replace uses of sprintf(3) with snprintf(3)." 2014-10-09 00:13:06 +00:00
gethnamaddr.c am 59de803a: Merge "libc should use O_CLOEXEC when opening files for its own use." 2014-08-26 23:41:23 +00:00