mirror of
https://github.com/yuzu-emu/yuzu-android.git
synced 2025-06-12 12:18:00 -05:00
Core: Properly configure address space when loading a binary
The code now properly configures the process image to match the loaded binary segments (code, rodata, data) instead of just blindly allocating a large chunk of dummy memory.
This commit is contained in:
@ -37,7 +37,7 @@ ArchiveFactory_SaveData::ArchiveFactory_SaveData(const std::string& sdmc_directo
|
||||
}
|
||||
|
||||
ResultVal<std::unique_ptr<ArchiveBackend>> ArchiveFactory_SaveData::Open(const Path& path) {
|
||||
std::string concrete_mount_point = GetSaveDataPath(mount_point, Kernel::g_current_process->program_id);
|
||||
std::string concrete_mount_point = GetSaveDataPath(mount_point, Kernel::g_current_process->codeset->program_id);
|
||||
if (!FileUtil::Exists(concrete_mount_point)) {
|
||||
// When a SaveData archive is created for the first time, it is not yet formatted
|
||||
// and the save file/directory structure expected by the game has not yet been initialized.
|
||||
@ -52,7 +52,7 @@ ResultVal<std::unique_ptr<ArchiveBackend>> ArchiveFactory_SaveData::Open(const P
|
||||
}
|
||||
|
||||
ResultCode ArchiveFactory_SaveData::Format(const Path& path) {
|
||||
std::string concrete_mount_point = GetSaveDataPath(mount_point, Kernel::g_current_process->program_id);
|
||||
std::string concrete_mount_point = GetSaveDataPath(mount_point, Kernel::g_current_process->codeset->program_id);
|
||||
FileUtil::DeleteDirRecursively(concrete_mount_point);
|
||||
FileUtil::CreateFullPath(concrete_mount_point);
|
||||
return RESULT_SUCCESS;
|
||||
|
Reference in New Issue
Block a user