mirror of
https://github.com/yuzu-emu/yuzu-android.git
synced 2025-06-13 15:58:44 -05:00
Kernel: Correct Cancel Synchronization.
This commit corrects the behavior of cancel synchronization when the thread is running/ready and ensures the next wait is cancelled as it's suppose to.
This commit is contained in:
committed by
FernandoS27
parent
bb31df62bb
commit
7d16b2d2dd
@ -505,6 +505,11 @@ static ResultCode WaitSynchronization(Core::System& system, Handle* index, VAddr
|
||||
return RESULT_TIMEOUT;
|
||||
}
|
||||
|
||||
if (thread->IsSyncCancelled()) {
|
||||
thread->SetSyncCancelled(false);
|
||||
return ERR_SYNCHRONIZATION_CANCELED;
|
||||
}
|
||||
|
||||
for (auto& object : objects) {
|
||||
object->AddWaitingThread(thread);
|
||||
}
|
||||
|
Reference in New Issue
Block a user