The man page says:
The getaddrinfo(3) function is not limited to creating IPv4 socket address structures; IPv6 socket address structures can be created if IPv6 support is available. These socket address structures can be used directly by bind(2) or connect(2), to prepare a client or a server socket.
What should I do to force getaddrinfo
to not create IPv6 socket address structures?
getaddrinfo
withAF_UNSPEC
not to use IPv6? – Gilles 'SO- stop being evil' Aug 16 '12 at 22:58