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

Enable parallelization of NewContentHashFunc #1744

Merged
merged 1 commit into from
Oct 21, 2020

Conversation

hinshun
Copy link
Collaborator

@hinshun hinshun commented Oct 21, 2020

I noticed this while working on code related to the solver. The bug noted by the FIXME is very likely the common issue with for loops + goroutines. The variable sel is not in the closure of the function, so you can fix it by re-declaring the variables in the body of the loop, or calling it with an anonymous function. Re-declaring seems cleaner because there's less nesting.

Signed-off-by: Edgar Lee <edgarl@netflix.com>
Copy link
Collaborator

@coryb coryb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGMT

@tonistiigi tonistiigi merged commit 20ac108 into moby:master Oct 21, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants