mirror of
https://github.com/KytyPS5/KytyPS5.git
synced 2026-10-28 08:13:05 +00:00
fix teardown
This commit is contained in:
1 parent
a20cf5d298
commit
93774ee37c
1 file changed
+2
-12
+2
-12
@@ -160,24 +160,14 @@ static void LoadElf(const std::filesystem::path& elf, bool dbg_print_reloc = fal
|
|||||||
}
|
}
|
||||||
|
|
||||||
static void Execute() {
|
static void Execute() {
|
||||||
int thread_model = 1;
|
Common::Thread guest_thread(
|
||||||
|
|
||||||
if (thread_model == 0) {
|
|
||||||
Common::Thread t([](void* /*unused*/) { Libs::Graphics::WindowRun(); }, nullptr);
|
|
||||||
t.Detach();
|
|
||||||
auto* rt = Common::Singleton<Loader::RuntimeLinker>::Instance();
|
|
||||||
rt->Execute();
|
|
||||||
} else {
|
|
||||||
Common::Thread t(
|
|
||||||
[](void* /*unused*/) {
|
[](void* /*unused*/) {
|
||||||
auto* rt = Common::Singleton<Loader::RuntimeLinker>::Instance();
|
auto* rt = Common::Singleton<Loader::RuntimeLinker>::Instance();
|
||||||
rt->Execute();
|
rt->Execute();
|
||||||
},
|
},
|
||||||
nullptr);
|
nullptr);
|
||||||
t.Detach();
|
|
||||||
Libs::Graphics::WindowRun();
|
Libs::Graphics::WindowRun();
|
||||||
t.Join();
|
std::quick_exit(0);
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void Run(const RunOptions& options) {
|
void Run(const RunOptions& options) {
|
||||||
|
|||||||
Reference in new issue
Block a user