This is the mail archive of the glibc-bugs@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug network/15726] getaddrinfo() returns incorrect status


http://sourceware.org/bugzilla/show_bug.cgi?id=15726

--- Comment #14 from Rich Felker <bugdal at aerifal dot cx> ---
On Thu, Jul 18, 2013 at 07:03:09AM +0000, carlos at redhat dot com wrote:
> What about EAI_NODATA which glibc still uses? It would seem that EAI_NODATA is
> more likely be returned in the current implementation than EAI_NONAME (which is
> mostly returned for the parameter errors discussed).

EAI_NODATA is not even in the specification for this function; I don't
know why it exists at all, as it could badly confuse conforming
applications which don't expect a positive "successful query with no
result" return code other than the specified EAI_NONAME.

On the other hand, I see the motivation, at least according to the
documentation. The Linux man page suggests glibc is using EAI_NONAME
when there is no such host/domain name, and EAI_NODATA when the
hostname exists but does not have any A or AAAA records (nor a CNAME
pointing to one that does).

Is it behaving differently from how it's documented?

-- 
You are receiving this mail because:
You are on the CC list for the bug.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]