Properly check for thread-safe getaddrinfo if it's unknown.