mirror of
https://github.com/Ed94/Odin.git
synced 2026-08-06 07:38:48 +00:00
if -> while in wait_signal_until_available to check for spurious wake-ups
This commit is contained in:
+1
-1
@@ -112,7 +112,7 @@ struct Wait_Signal {
|
|||||||
};
|
};
|
||||||
|
|
||||||
gb_internal void wait_signal_until_available(Wait_Signal *ws) {
|
gb_internal void wait_signal_until_available(Wait_Signal *ws) {
|
||||||
if (ws->futex.load() == 0) {
|
while (ws->futex.load() == 0) {
|
||||||
futex_wait(&ws->futex, 1);
|
futex_wait(&ws->futex, 1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user