-
Notifications
You must be signed in to change notification settings - Fork 17.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
net: DefaultResolver.LookupIP returns no error and nil IP address for empty string #53995
Comments
It seems that return |
Change https://go.dev/cl/419734 mentions this issue: |
i send a wip cl and want help. I'm wondering if it's more appropriate to return an error, or just return an empty slice. please feel free to review |
Looking up an empty host name should probably return some sort of error. |
pleas feel free to review |
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
Yes.
What operating system and processor architecture are you using (
go env
)?go env
OutputWhat did you do?
https://go.dev/play/p/o1nR6WBsGQT
What did you expect to see?
An error when looking up the empty hostname.
What did you see instead?
No error and a nil IP address.
The text was updated successfully, but these errors were encountered: