Fix _sys_interrupt_thread_disestablish with lingering thread copies

This commit is contained in:
Eladash 2023-06-06 08:18:30 +03:00 committed by Megamouse
parent 4af0a33f1f
commit 9bd4426225

View File

@ -214,6 +214,9 @@ error_code _sys_interrupt_thread_disestablish(ppu_thread& ppu, u32 ih, vm::ptr<u
if (const auto thread = idm::withdraw<named_thread<ppu_thread>>(ih))
{
*r13 = thread->gpr[13];
// It is detached from IDM now so join must be done explicitly now
*thread = thread_state::finished;
return CELL_OK;
}