mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-02-02 18:05:20 +00:00
e146f4beef
The virNetSocketCheckProtocols() function is supposed to tell caller whether IPv4 and/or IPv6 is supported on the system. In the initial round, it uses getifaddrs() to see if an interface has IPv4/IPv6 address assigned and then to double check IPv6 it uses getaddrinfo() to lookup IPv6 loopback address. Separate out this latter code because it is going to be reused. Since the original code lived under an #ifdef and the new function doesn't it is marked as unused - because on some systems it may be so. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> Reviewed-by: Ján Tomko <jtomko@redhat.com>