mirror of
https://github.com/corda/corda.git
synced 2025-02-01 00:45:59 +00:00
Merge pull request #434 from joshuawarner32/master
fix concurrency bugs on ios+arm64 in `enter`
This commit is contained in:
commit
d42a354f7d
@ -4040,6 +4040,8 @@ void enter(Thread* t, Thread::State s)
|
||||
|
||||
t->state = s;
|
||||
|
||||
STORE_LOAD_MEMORY_BARRIER;
|
||||
|
||||
if (t->m->exclusive) {
|
||||
ACQUIRE_LOCK;
|
||||
|
||||
@ -4091,6 +4093,8 @@ void enter(Thread* t, Thread::State s)
|
||||
|
||||
t->state = s;
|
||||
|
||||
STORE_LOAD_MEMORY_BARRIER;
|
||||
|
||||
if (t->m->exclusive) {
|
||||
// another thread has entered the exclusive state, so we
|
||||
// return to idle and use the slow path to become active
|
||||
|
Loading…
x
Reference in New Issue
Block a user