Skip to content

Encapsulate election mutex#4310

Merged
clemahieu merged 3 commits intonanocurrency:developfrom
gr0vity-dev:prs/encapsulate_election_mutex
Oct 19, 2023
Merged

Encapsulate election mutex#4310
clemahieu merged 3 commits intonanocurrency:developfrom
gr0vity-dev:prs/encapsulate_election_mutex

Conversation

@gr0vity-dev
Copy link
Copy Markdown
Contributor

This PR fixes an issue pointed out by @pwojcikdev introduced in #4306 where in notify_observers,
auto status = election->status;was called without holding the election lock.

It makes use of @simpago work of encapsulating the mutex of election class for rsnano.

- fix issue in notify_observers() where the lock was missing for `auto status = election->status;`
- make use of `set_status_type ()` returning the updated election status
@clemahieu clemahieu force-pushed the prs/encapsulate_election_mutex branch from 85bcaae to 8f1721a Compare October 19, 2023 14:42
@clemahieu clemahieu merged commit f30ec11 into nanocurrency:develop Oct 19, 2023
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