summaryrefslogtreecommitdiffstats
path: root/src/citra
diff options
context:
space:
mode:
authorSubv <subv2112@gmail.com>2016-11-27 05:13:40 +0100
committerSubv <subv2112@gmail.com>2016-11-28 00:03:48 +0100
commitd171409f29ce3d8bcf7ed6ce16392b4b4ec97c4b (patch)
tree25b4b0c9fd1f316812c3eb74310b9a31f872a4f5 /src/citra
parentKernel/Loader: Grab the system mode from the NCCH ExHeader. (diff)
downloadyuzu-d171409f29ce3d8bcf7ed6ce16392b4b4ec97c4b.tar
yuzu-d171409f29ce3d8bcf7ed6ce16392b4b4ec97c4b.tar.gz
yuzu-d171409f29ce3d8bcf7ed6ce16392b4b4ec97c4b.tar.bz2
yuzu-d171409f29ce3d8bcf7ed6ce16392b4b4ec97c4b.tar.lz
yuzu-d171409f29ce3d8bcf7ed6ce16392b4b4ec97c4b.tar.xz
yuzu-d171409f29ce3d8bcf7ed6ce16392b4b4ec97c4b.tar.zst
yuzu-d171409f29ce3d8bcf7ed6ce16392b4b4ec97c4b.zip
Diffstat (limited to 'src/citra')
-rw-r--r--src/citra/citra.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/citra/citra.cpp b/src/citra/citra.cpp
index c742be231..f9387e61c 100644
--- a/src/citra/citra.cpp
+++ b/src/citra/citra.cpp
@@ -135,17 +135,17 @@ int main(int argc, char** argv) {
return -1;
}
- u32 system_mode;
- Loader::ResultStatus load_result = loader->LoadKernelSystemMode(system_mode);
- if (Loader::ResultStatus::Success != load_result) {
- LOG_CRITICAL(Frontend, "Failed to load ROM (Error %i)!", load_result);
+ boost::optional<u32> system_mode = loader->LoadKernelSystemMode();
+
+ if (!system_mode) {
+ LOG_CRITICAL(Frontend, "Failed to load ROM (Could not determine system mode)!");
return -1;
}
- System::Init(emu_window.get(), system_mode);
+ System::Init(emu_window.get(), system_mode.get());
SCOPE_EXIT({ System::Shutdown(); });
- load_result = loader->Load();
+ Loader::ResultStatus load_result = loader->Load();
if (Loader::ResultStatus::Success != load_result) {
LOG_CRITICAL(Frontend, "Failed to load ROM (Error %i)!", load_result);
return -1;