This is the mail archive of the
libc-alpha@sourceware.cygnus.com
mailing list for the glibc project.
Re: problems with getaddrinfo() and _res.options
On Sat, May 27, Ulrich Drepper wrote:
> Philip Blundell <Philip.Blundell@pobox.com> writes:
>
> > >As a consequence of these changes getaddrinfo() now does not return
> > >the IPv4 and IPv6 address of a host if AF_UNSPEC is passed in as the
> > >protocol. This is another change, but again a useful one.
> >
> > This will break all existing dual-stack applications. Standard
> > practice up until now has been to use AF_UNSPEC and expect to get
> > back both IPv4 and IPv6 addresses. (I think this is true for all
> > platforms, not just Linux.)
>
> Why, it makes no sense. If you can handle both, IPv4 and IPv6, why
> should you get the mapped IPv4 address back? I just tried it on
> Solaris 8. You only get the IPv4 address.
I don't think that Philip spoke about mapped IPv6 addresses.
If a host has a real IPv4 and a real IPv6 address, with AF_UNSPEC both
addresses should give back, not only a IPv4 or IPv6.
Thorsten
--
Thorsten Kukuk http://www.suse.de/~kukuk/ kukuk@suse.de
SuSE GmbH Schanzaeckerstr. 10 90443 Nuernberg
Linux is like a Vorlon. It is incredibly powerful, gives terse,
cryptic answers and has a lot of things going on in the background.