summaryrefslogtreecommitdiffstats
path: root/src/core/file_sys/romfs_factory.cpp
diff options
context:
space:
mode:
authorMorph <39850852+Morph1984@users.noreply.github.com>2021-11-02 22:23:19 +0100
committerMorph <39850852+Morph1984@users.noreply.github.com>2021-11-02 22:23:19 +0100
commitcb09ea0f0174162a85f47fdb8446b397c3c57e20 (patch)
tree5cbd9a62e1daf1c1de97444858064fe8210df077 /src/core/file_sys/romfs_factory.cpp
parenthle/result: Amend ResultVal documentation (diff)
downloadyuzu-cb09ea0f0174162a85f47fdb8446b397c3c57e20.tar
yuzu-cb09ea0f0174162a85f47fdb8446b397c3c57e20.tar.gz
yuzu-cb09ea0f0174162a85f47fdb8446b397c3c57e20.tar.bz2
yuzu-cb09ea0f0174162a85f47fdb8446b397c3c57e20.tar.lz
yuzu-cb09ea0f0174162a85f47fdb8446b397c3c57e20.tar.xz
yuzu-cb09ea0f0174162a85f47fdb8446b397c3c57e20.tar.zst
yuzu-cb09ea0f0174162a85f47fdb8446b397c3c57e20.zip
Diffstat (limited to 'src/core/file_sys/romfs_factory.cpp')
-rw-r--r--src/core/file_sys/romfs_factory.cpp10
1 files changed, 4 insertions, 6 deletions
diff --git a/src/core/file_sys/romfs_factory.cpp b/src/core/file_sys/romfs_factory.cpp
index 638c6cea8..3d9ce863b 100644
--- a/src/core/file_sys/romfs_factory.cpp
+++ b/src/core/file_sys/romfs_factory.cpp
@@ -39,13 +39,12 @@ void RomFSFactory::SetPackedUpdate(VirtualFile update_raw_file) {
ResultVal<VirtualFile> RomFSFactory::OpenCurrentProcess(u64 current_process_title_id) const {
if (!updatable) {
- return MakeResult<VirtualFile>(file);
+ return file;
}
const PatchManager patch_manager{current_process_title_id, filesystem_controller,
content_provider};
- return MakeResult<VirtualFile>(
- patch_manager.PatchRomFS(file, ivfc_offset, ContentRecordType::Program, update_raw));
+ return patch_manager.PatchRomFS(file, ivfc_offset, ContentRecordType::Program, update_raw);
}
ResultVal<VirtualFile> RomFSFactory::OpenPatchedRomFS(u64 title_id, ContentRecordType type) const {
@@ -58,8 +57,7 @@ ResultVal<VirtualFile> RomFSFactory::OpenPatchedRomFS(u64 title_id, ContentRecor
const PatchManager patch_manager{title_id, filesystem_controller, content_provider};
- return MakeResult<VirtualFile>(
- patch_manager.PatchRomFS(nca->GetRomFS(), nca->GetBaseIVFCOffset(), type));
+ return patch_manager.PatchRomFS(nca->GetRomFS(), nca->GetBaseIVFCOffset(), type);
}
ResultVal<VirtualFile> RomFSFactory::OpenPatchedRomFSWithProgramIndex(
@@ -83,7 +81,7 @@ ResultVal<VirtualFile> RomFSFactory::Open(u64 title_id, StorageId storage,
return ResultUnknown;
}
- return MakeResult<VirtualFile>(romfs);
+ return romfs;
}
std::shared_ptr<NCA> RomFSFactory::GetEntry(u64 title_id, StorageId storage,