Don't try to create an IPV6 socket when unecessary

Specifically, if there are no IPV6 nameservers in the configured nameserver list, there's no reason
to open an IPV6 socket.