summaryrefslogtreecommitdiffstats
path: root/src/core/file_sys
diff options
context:
space:
mode:
authorZach Hilman <zachhilman@gmail.com>2018-07-31 18:27:14 +0200
committerZach Hilman <zachhilman@gmail.com>2018-08-01 06:16:54 +0200
commit13cdf1f15952cdce306e8c241b7d156496f72fe5 (patch)
tree143ad74beb91c974289b256373ae52d9e24a8b64 /src/core/file_sys
parentFix merge conflicts with opus and update docs (diff)
downloadyuzu-13cdf1f15952cdce306e8c241b7d156496f72fe5.tar
yuzu-13cdf1f15952cdce306e8c241b7d156496f72fe5.tar.gz
yuzu-13cdf1f15952cdce306e8c241b7d156496f72fe5.tar.bz2
yuzu-13cdf1f15952cdce306e8c241b7d156496f72fe5.tar.lz
yuzu-13cdf1f15952cdce306e8c241b7d156496f72fe5.tar.xz
yuzu-13cdf1f15952cdce306e8c241b7d156496f72fe5.tar.zst
yuzu-13cdf1f15952cdce306e8c241b7d156496f72fe5.zip
Diffstat (limited to 'src/core/file_sys')
-rw-r--r--src/core/file_sys/content_archive.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/core/file_sys/content_archive.cpp b/src/core/file_sys/content_archive.cpp
index 2deb727cc..79e70f6ef 100644
--- a/src/core/file_sys/content_archive.cpp
+++ b/src/core/file_sys/content_archive.cpp
@@ -188,11 +188,11 @@ NCA::NCA(VirtualFile file_) : file(std::move(file_)) {
header.section_tables[i].media_offset * MEDIA_OFFSET_MULTIPLIER +
section.romfs.ivfc.levels[IVFC_MAX_LEVEL - 1].offset;
const size_t romfs_size = section.romfs.ivfc.levels[IVFC_MAX_LEVEL - 1].size;
- const auto dec =
+ auto dec =
Decrypt(section, std::make_shared<OffsetVfsFile>(file, romfs_size, romfs_offset),
romfs_offset);
if (dec != nullptr) {
- files.emplace_back();
+ files.push_back(std::move(dec));
romfs = files.back();
} else {
status = Loader::ResultStatus::ErrorMissingKeys;
@@ -204,13 +204,13 @@ NCA::NCA(VirtualFile file_) : file(std::move(file_)) {
section.pfs0.pfs0_header_offset;
u64 size = MEDIA_OFFSET_MULTIPLIER * (header.section_tables[i].media_end_offset -
header.section_tables[i].media_offset);
- const auto dec =
+ auto dec =
Decrypt(section, std::make_shared<OffsetVfsFile>(file, size, offset), offset);
if (dec != nullptr) {
- auto npfs = std::make_shared<PartitionFilesystem>(dec);
+ auto npfs = std::make_shared<PartitionFilesystem>(std::move(dec));
if (npfs->GetStatus() == Loader::ResultStatus::Success) {
- dirs.emplace_back(npfs);
+ dirs.push_back(std::move(npfs));
if (IsDirectoryExeFS(dirs.back()))
exefs = dirs.back();
}