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

Add missing locks around broadcasts #996

Merged
merged 1 commit into from
May 11, 2019
Merged

Conversation

msg555
Copy link
Contributor

@msg555 msg555 commented May 9, 2019

To avoid race conditions related to broadcasting prior to the intended thread having invoked Wait already you need to lock the wrapping mutex before broadcasting.

https://pastebin.com/tNitJ5L2 demonstrates why unlocked broadcasts are problematic.

Copy link
Member

@thaJeztah thaJeztah left a comment

Choose a reason for hiding this comment

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

@msg555 could you perhaps update your sign-off to use your actual name (instead of msg)?

Signed-off-by: msg <[email protected]>

You can configure your name in your git configuration (so it would use it automatically if you use commit -s next time)

@msg555
Copy link
Contributor Author

msg555 commented May 10, 2019

Updated sign off, my mistake

Copy link
Member

@thaJeztah thaJeztah left a comment

Choose a reason for hiding this comment

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

no worries! Thanks for fixing the sign off

LGTM

@thaJeztah thaJeztah merged commit 3780f5d into moby:master May 11, 2019
@thaJeztah
Copy link
Member

thank you!

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.

3 participants