ThreadBase rewritten (wip)

This commit is contained in:
Nekotekina 2015-07-01 01:25:52 +03:00
parent b7a320fbbd
commit 3aefa2b4e1
85 changed files with 1960 additions and 2183 deletions

View file

@ -179,24 +179,25 @@ namespace sce_libc_func
std::lock_guard<std::mutex> lock(g_atexit_mutex);
if (!Emu.IsStopped())
CHECK_EMU_STATUS;
for (auto func : decltype(g_atexit)(std::move(g_atexit)))
{
for (auto func : decltype(g_atexit)(std::move(g_atexit)))
{
func(context);
}
func(context);
}
sceLibc.Success("Process finished");
sceLibc.Success("Process finished");
CallAfter([]()
{
Emu.Stop();
});
CallAfter([]()
{
Emu.Stop();
});
while (!Emu.IsStopped())
{
std::this_thread::sleep_for(std::chrono::milliseconds(1));
}
while (true)
{
CHECK_EMU_STATUS;
std::this_thread::sleep_for(std::chrono::milliseconds(1));
}
}