On Fri, Oct 31, 2008 at 12:37:16PM -0500, Anthony Liguori wrote:
Gerd's patch does 'do the right thing' for 90% of people - it uses the
AI_ADDRCONFIG flag. This means that the getaddrinfo() name lookup will
only return an IPv6 address if there is at least one NIC with IPv6
configured, likewise only return an IPv4 address if there is at least
one NIC with IPv4 configured. There are still times when it is desirable
to restrict it to just IPv4 or just IPv6, regardless of your host NIC
config - mostly when needing to interact with other broken apps which are
not correctly IPv6 aware. Maybe it would be sufficient to just have it added
as a flag to the arg in question though, eg -serial tcp:localhost:123,ipv4
rather than a global -ipv4 flag