
Hi, the module Network.Socket provides 'getaddrinfo' only if IPv6 support is enabled. That surprises me because, as far as I know, there is nothing IPv6-specific about that function. Does anyone know why that choice was made? Best regards, Peter

Peter Simons wrote:
the module Network.Socket provides 'getaddrinfo' only if IPv6 support is enabled. That surprises me because, as far as I know, there is nothing IPv6-specific about that function.
The RFC that introduced it did so for the purpose of supporting IPv6. The configure checks don't care if IPv6 is actually enabled, merely that there's a working IPv6-capable API. You can then use getAddrInfo on IPv4 or IPv6 addresses as you wish.

the module Network.Socket provides 'getaddrinfo' only if IPv6 support is enabled.
Meanwhile, I found out that the configure check that determines whether IPv6 support is available or not looks like this: dnl -------------------------------------------------- dnl * test for getaddrinfo as proxy for IPv6 support dnl -------------------------------------------------- AC_CHECK_FUNCS(getaddrinfo) Apparently I was worried for no reason. :-) Thanks for responding, Bryan. Best regards, Peter
participants (2)
-
Bryan O'Sullivan
-
Peter Simons