aboutsummaryrefslogtreecommitdiff
path: root/src/core/loader/xci.cpp
diff options
context:
space:
mode:
authorLioncash <mathew1800@gmail.com>2020-09-16 08:19:25 -0400
committerLioncash <mathew1800@gmail.com>2020-09-16 08:46:59 -0400
commit113a3972a6487430ab94f08a4a66742739ff48c2 (patch)
tree735e838e0e271449cecaedc6977c1831c9e39a3a /src/core/loader/xci.cpp
parent004bfefeb57898ad38af6255bc6ccc6bb1e35fbd (diff)
core/loader: Remove dependencies on the global system instance
Now all that remains is: 18 instances in file_sys code 14 instances in GDB stub code (this can be tossed wholesale) 4 instances in HLE code 2 instances in settings code.
Diffstat (limited to 'src/core/loader/xci.cpp')
-rw-r--r--src/core/loader/xci.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/core/loader/xci.cpp b/src/core/loader/xci.cpp
index 7186ad1ff1..25e83af0f6 100644
--- a/src/core/loader/xci.cpp
+++ b/src/core/loader/xci.cpp
@@ -49,7 +49,7 @@ FileType AppLoader_XCI::IdentifyType(const FileSys::VirtualFile& file) {
return FileType::Error;
}
-AppLoader_XCI::LoadResult AppLoader_XCI::Load(Kernel::Process& process) {
+AppLoader_XCI::LoadResult AppLoader_XCI::Load(Kernel::Process& process, Core::System& system) {
if (is_loaded) {
return {ResultStatus::ErrorAlreadyLoaded, {}};
}
@@ -66,15 +66,14 @@ AppLoader_XCI::LoadResult AppLoader_XCI::Load(Kernel::Process& process) {
return {ResultStatus::ErrorMissingProductionKeyFile, {}};
}
- const auto result = nca_loader->Load(process);
+ const auto result = nca_loader->Load(process, system);
if (result.first != ResultStatus::Success) {
return result;
}
FileSys::VirtualFile update_raw;
if (ReadUpdateRaw(update_raw) == ResultStatus::Success && update_raw != nullptr) {
- Core::System::GetInstance().GetFileSystemController().SetPackedUpdate(
- std::move(update_raw));
+ system.GetFileSystemController().SetPackedUpdate(std::move(update_raw));
}
is_loaded = true;