summaryrefslogtreecommitdiffstats
path: root/src/core/core.cpp
diff options
context:
space:
mode:
authorbunnei <bunneidev@gmail.com>2017-09-29 20:58:42 +0200
committerGitHub <noreply@github.com>2017-09-29 20:58:42 +0200
commitb07af7dda822898e9c8f231c5ddcd1741d93dbef (patch)
treed41c9221d6065b8cf9e6a2405565b675a9c83c51 /src/core/core.cpp
parentMerge pull request #2907 from Subv/warnings3 (diff)
parentLoaders: Don't automatically set the current process every time we load an application. (diff)
downloadyuzu-b07af7dda822898e9c8f231c5ddcd1741d93dbef.tar
yuzu-b07af7dda822898e9c8f231c5ddcd1741d93dbef.tar.gz
yuzu-b07af7dda822898e9c8f231c5ddcd1741d93dbef.tar.bz2
yuzu-b07af7dda822898e9c8f231c5ddcd1741d93dbef.tar.lz
yuzu-b07af7dda822898e9c8f231c5ddcd1741d93dbef.tar.xz
yuzu-b07af7dda822898e9c8f231c5ddcd1741d93dbef.tar.zst
yuzu-b07af7dda822898e9c8f231c5ddcd1741d93dbef.zip
Diffstat (limited to 'src/core/core.cpp')
-rw-r--r--src/core/core.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/core/core.cpp b/src/core/core.cpp
index 59b8768e7..0c7a72987 100644
--- a/src/core/core.cpp
+++ b/src/core/core.cpp
@@ -13,6 +13,7 @@
#include "core/core_timing.h"
#include "core/gdbstub/gdbstub.h"
#include "core/hle/kernel/kernel.h"
+#include "core/hle/kernel/process.h"
#include "core/hle/kernel/thread.h"
#include "core/hle/service/service.h"
#include "core/hw/hw.h"
@@ -100,7 +101,7 @@ System::ResultStatus System::Load(EmuWindow* emu_window, const std::string& file
return init_result;
}
- const Loader::ResultStatus load_result{app_loader->Load()};
+ const Loader::ResultStatus load_result{app_loader->Load(Kernel::g_current_process)};
if (Loader::ResultStatus::Success != load_result) {
LOG_CRITICAL(Core, "Failed to load ROM (Error %i)!", load_result);
System::Shutdown();
@@ -114,6 +115,7 @@ System::ResultStatus System::Load(EmuWindow* emu_window, const std::string& file
return ResultStatus::ErrorLoader;
}
}
+ Memory::SetCurrentPageTable(&Kernel::g_current_process->vm_manager.page_table);
status = ResultStatus::Success;
return status;
}
@@ -196,4 +198,4 @@ void System::Shutdown() {
LOG_DEBUG(Core, "Shutdown OK");
}
-} // namespace
+} // namespace Core