Fix Emulator::Stop race with IDM

Newly created threads' state could have not been flagged with exit.
This commit is contained in:
Eladash 2021-03-03 06:05:21 +02:00 committed by Ivan
parent e9bea1c742
commit dea1d01de2

View File

@ -614,6 +614,12 @@ cpu_thread::cpu_thread(u32 id)
break;
}
if (Emu.IsStopped())
{
// For similar race as above
state += cpu_flag::exit;
}
g_threads_created++;
}