Merge pull request #8483 from liamwhite/fire-emblem-three-semaphores

kernel: wait for threads to stop on pause
This commit is contained in:
bunnei authored and GitHub committed 2022-06-22 14:46:33 -07:00
commit 9da4e62573
3 files changed
+22

No files matched your search

+7
View File
@@ -1078,6 +1078,13 @@ void KernelCore::Suspend(bool suspended) {
for (auto* process : GetProcessList()) {
process->SetActivity(activity);
if (should_suspend) {
// Wait for execution to stop
for (auto* thread : process->GetThreadList()) {
thread->WaitUntilSuspended();
}
}
}
}