[*] Nt Condvars: I'm paranoid about this potential race condition
This commit is contained in:
parent
09401cecd6
commit
718b5a9316
@ -307,6 +307,14 @@ namespace Aurora::Threading::Primitives
|
|||||||
if (uSignalNext == 0)
|
if (uSignalNext == 0)
|
||||||
{
|
{
|
||||||
InterlockedOr((volatile LONG *)&this->wlist, 1);
|
InterlockedOr((volatile LONG *)&this->wlist, 1);
|
||||||
|
|
||||||
|
// paranoia
|
||||||
|
#if 1
|
||||||
|
if (AuAtomicLoad(&this->signalCount) != 0) [[unlikely]]
|
||||||
|
{
|
||||||
|
AuAtomicUnset(&this->wlist, 0);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user