mirror of
https://github.com/yuzu-emu/yuzu-android.git
synced 2024-11-23 00:45:43 +01:00
Kernel/Semaphore: Fixed a regression in semaphore waits.
The regression was caused by a missing check in #2260. The new behavior is consistent with the real kernel.
This commit is contained in:
parent
f20d872643
commit
4251eb26ec
@ -35,7 +35,8 @@ bool Semaphore::ShouldWait(Thread* thread) const {
|
||||
}
|
||||
|
||||
void Semaphore::Acquire(Thread* thread) {
|
||||
ASSERT_MSG(!ShouldWait(thread), "object unavailable!");
|
||||
if (available_count <= 0)
|
||||
return;
|
||||
--available_count;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user