handle gethostbyname return value for unresolvable hostnames