safer exception handling in HostnameFetcher