mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-10-27 12:18:35 +01:00
Fix an ancient bug in sceKernelExitDeleteThread
This commit is contained in:
1 parent
7590a44fc4
commit
4cdbe0b957
1 file changed
+3
-1
@@ -2149,6 +2149,8 @@ void sceKernelExitDeleteThread(int exitStatus)
|
||||
if (thread)
|
||||
{
|
||||
INFO_LOG(SCEKERNEL,"sceKernelExitDeleteThread(%d)", exitStatus);
|
||||
uint32_t thread_attr = thread->nt.attr;
|
||||
uint32_t uid = thread->GetUID();
|
||||
__KernelDeleteThread(currentThread, exitStatus, "thread exited with delete");
|
||||
// Temporary hack since we don't reschedule within callbacks.
|
||||
g_inCbCount = 0;
|
||||
@@ -2156,7 +2158,7 @@ void sceKernelExitDeleteThread(int exitStatus)
|
||||
hleReSchedule("thread exited with delete");
|
||||
|
||||
// TODO: This should trigger ON the thread when it exits.
|
||||
__KernelThreadTriggerEvent((thread->nt.attr & PSP_THREAD_ATTR_KERNEL) != 0, thread->GetUID(), THREADEVENT_EXIT);
|
||||
__KernelThreadTriggerEvent((thread_attr & PSP_THREAD_ATTR_KERNEL) != 0, uid, THREADEVENT_EXIT);
|
||||
}
|
||||
else
|
||||
ERROR_LOG_REPORT(SCEKERNEL, "sceKernelExitDeleteThread(%d) ERROR - could not find myself!", exitStatus);
|
||||
|
||||
Reference in new issue
Block a user