Kernel: Store the program id in the Process class instead of the CodeSet class.
There may be many CodeSets per Process, so it's wasteful and overcomplicated to store the program id in each of them.
This commit is contained in:
parent
cc6e4ae6cf
commit
827f8ca3c7
9 changed files with 25 additions and 26 deletions
|
@ -83,7 +83,7 @@ bool AppLoader_NRO::LoadNro(const std::string& path, VAddr load_base) {
|
|||
}
|
||||
|
||||
// Build program image
|
||||
Kernel::SharedPtr<Kernel::CodeSet> codeset = Kernel::CodeSet::Create("", 0);
|
||||
Kernel::SharedPtr<Kernel::CodeSet> codeset = Kernel::CodeSet::Create("");
|
||||
std::vector<u8> program_image;
|
||||
program_image.resize(PageAlignSize(nro_header.file_size));
|
||||
file.Seek(0, SEEK_SET);
|
||||
|
@ -125,7 +125,7 @@ ResultStatus AppLoader_NRO::Load(Kernel::SharedPtr<Kernel::Process>& process) {
|
|||
return ResultStatus::Error;
|
||||
}
|
||||
|
||||
process = Kernel::Process::Create("main");
|
||||
process = Kernel::Process::Create("main", 0);
|
||||
|
||||
// Load NRO
|
||||
static constexpr VAddr base_addr{Memory::PROCESS_IMAGE_VADDR};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue