summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar bunnei2020-04-20 18:16:31 -0400
committerGravatar bunnei2020-04-20 18:19:45 -0400
commit68039addbc8b572c362adbf2a4615938bbf27c63 (patch)
tree9bbedd14a0625ae33c1839016eb46bf51a2bbf10
parentfile_sys: program_metadata: Add a helper function for generating reasonable d... (diff)
downloadyuzu-68039addbc8b572c362adbf2a4615938bbf27c63.tar.gz
yuzu-68039addbc8b572c362adbf2a4615938bbf27c63.tar.xz
yuzu-68039addbc8b572c362adbf2a4615938bbf27c63.zip
loader: elf: Fix process initialization using ProgramMetadata default.
-rw-r--r--src/core/loader/elf.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/core/loader/elf.cpp b/src/core/loader/elf.cpp
index 1e9ed2837..8f7615115 100644
--- a/src/core/loader/elf.cpp
+++ b/src/core/loader/elf.cpp
@@ -398,6 +398,11 @@ AppLoader_ELF::LoadResult AppLoader_ELF::Load(Kernel::Process& process) {
398 Kernel::CodeSet codeset = elf_reader.LoadInto(base_address); 398 Kernel::CodeSet codeset = elf_reader.LoadInto(base_address);
399 const VAddr entry_point = codeset.entrypoint; 399 const VAddr entry_point = codeset.entrypoint;
400 400
401 // Setup the process code layout
402 if (process.LoadFromMetadata(FileSys::ProgramMetadata::GetDefault(), buffer.size()).IsError()) {
403 return {ResultStatus::ErrorNotInitialized, {}};
404 }
405
401 process.LoadModule(std::move(codeset), entry_point); 406 process.LoadModule(std::move(codeset), entry_point);
402 407
403 is_loaded = true; 408 is_loaded = true;