mirror of
https://git.ryujinx.app/ryubing/ryujinx.git
synced 2025-07-31 10:09:42 -06:00
Add missing check for thread termination on ArbitrateLock (#4722)
* Add missing check for thread termination on ArbitrateLock * Use TerminationRequested in all places where it can be used
This commit is contained in:
@ -47,8 +47,7 @@ namespace Ryujinx.HLE.HOS.Kernel.Threading
|
||||
|
||||
KThread currentThread = KernelStatic.GetCurrentThread();
|
||||
|
||||
if (currentThread.ShallBeTerminated ||
|
||||
currentThread.SchedFlags == ThreadSchedState.TerminationPending)
|
||||
if (currentThread.TerminationRequested)
|
||||
{
|
||||
result = KernelResult.ThreadTerminating;
|
||||
}
|
||||
@ -61,7 +60,7 @@ namespace Ryujinx.HLE.HOS.Kernel.Threading
|
||||
else
|
||||
{
|
||||
LinkedListNode<KThread>[] syncNodesArray = ArrayPool<LinkedListNode<KThread>>.Shared.Rent(syncObjs.Length);
|
||||
|
||||
|
||||
Span<LinkedListNode<KThread>> syncNodes = syncNodesArray.AsSpan(0, syncObjs.Length);
|
||||
|
||||
for (int index = 0; index < syncObjs.Length; index++)
|
||||
|
Reference in New Issue
Block a user