Use WaitOnAddress instead of RtlWaitOnAddress

This commit is contained in:
gingerBill
2021-10-11 15:23:39 +01:00
parent 240b6aab13
commit 8c9299c139
2 changed files with 15 additions and 20 deletions
+4 -1
View File
@@ -154,6 +154,9 @@ cond_wait :: proc(c: ^Cond, m: ^Mutex) {
}
cond_wait_with_timeout :: proc(c: ^Cond, m: ^Mutex, duration: time.Duration) -> bool {
if duration <= 0 {
return false
}
return _cond_wait_with_timeout(c, m, duration)
}
@@ -215,7 +218,7 @@ futex_wait_with_timeout :: proc(f: ^Futex, expected: u32, duration: time.Duratio
if u32(atomic_load(f)) != expected {
return true
}
if duration == 0 {
if duration <= 0 {
return false
}