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

Protect ProposerPolicy Registry using Mutex #1242

Merged
merged 4 commits into from
Aug 25, 2021

Conversation

jbhurat
Copy link
Contributor

@jbhurat jbhurat commented Aug 24, 2021

RegisterValidatorSet() might throw a nil pointer, if the validatorSet registry is cleared in ClearRegistry() by another goroutine. To fix this access to registry needs to be protected.

Copy link
Contributor

@ricardolyn ricardolyn left a comment

Choose a reason for hiding this comment

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

LGTM

consensus/istanbul/backend/engine_test.go Show resolved Hide resolved
@ricardolyn ricardolyn merged commit 8d6c4e9 into Consensys:master Aug 25, 2021
danielporto pushed a commit to danielporto/quorum that referenced this pull request Sep 7, 2021
* Protect access to validator set in ProposerPolicy using mutex

* Making Registry private

* Moving eventLoop() to after calling Seal() as earlier stop channel might have triggered before calling Seal()
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.

2 participants