Skip to content
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: Error when running concurrent DNS queries using cgo on MacOS [1.12 backport] #31062

Closed
gopherbot opened this issue Mar 26, 2019 · 2 comments
Closed

Comments

@gopherbot
Copy link

@gopherbot gopherbot commented Mar 26, 2019

@mikioh requested issue #30521 to be considered for backport to the next 1.12 minor release.

@gopherbot please consider this for backport to 1.12

@gopherbot

This comment has been minimized.

Copy link
Author

@gopherbot gopherbot commented Apr 2, 2019

Change https://golang.org/cl/170320 mentions this issue: [release-branch.go1.12] net: use network and host as singleflight key during lookupIP

gopherbot pushed a commit that referenced this issue Apr 2, 2019
… during lookupIP

In CL 120215 the cgo resolver was changed to have different logic based
on the network being queried. However, the singleflight cache key wasn't
updated to also include the network. This way it was possible for
concurrent queries to return the result for the wrong network.

This CL changes the key to include both network and host, fixing the
problem.

Fixes #31062

Change-Id: I8b41b0ce1d9a02d18876c43e347654312eba22fc
Reviewed-on: https://go-review.googlesource.com/c/go/+/166037
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
(cherry picked from commit e341bae)
Reviewed-on: https://go-review.googlesource.com/c/go/+/170320
Run-TryBot: Andrew Bonventre <andybons@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
@gopherbot

This comment has been minimized.

Copy link
Author

@gopherbot gopherbot commented Apr 2, 2019

Closed by merging 578e281 to release-branch.go1.12.

@gopherbot gopherbot closed this Apr 2, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.