diff options
| author | 2018-09-19 19:19:05 -0400 | |
|---|---|---|
| committer | 2018-09-19 19:34:08 -0400 | |
| commit | 05ef9dfc10c3a52d1dfab50bb7b2a07891a2c3e9 (patch) | |
| tree | 3ea50f87bd2867732be3d68c3ba8207a5c95ad01 /src | |
| parent | Reworked incorrect nifm stubs (#1355) (diff) | |
| download | yuzu-05ef9dfc10c3a52d1dfab50bb7b2a07891a2c3e9.tar.gz yuzu-05ef9dfc10c3a52d1dfab50bb7b2a07891a2c3e9.tar.xz yuzu-05ef9dfc10c3a52d1dfab50bb7b2a07891a2c3e9.zip | |
file-sys: Default heavy-weight class destructors in the cpp file
Several classes have a lot of non-trivial members within them, or don't
but likely should have the destructor defaulted in the cpp file for
future-proofing/being more friendly to forward declarations.
Leaving the destructor unspecified allows the compiler to inline the
destruction code all over the place, which is generally undesirable from
a code bloat perspective.
Diffstat (limited to 'src')
25 files changed, 45 insertions, 1 deletions
diff --git a/src/core/file_sys/content_archive.cpp b/src/core/file_sys/content_archive.cpp index 45fc0b574..aa1b3c17d 100644 --- a/src/core/file_sys/content_archive.cpp +++ b/src/core/file_sys/content_archive.cpp | |||
| @@ -463,6 +463,8 @@ NCA::NCA(VirtualFile file_, VirtualFile bktr_base_romfs_, u64 bktr_base_ivfc_off | |||
| 463 | status = Loader::ResultStatus::Success; | 463 | status = Loader::ResultStatus::Success; |
| 464 | } | 464 | } |
| 465 | 465 | ||
| 466 | NCA::~NCA() = default; | ||
| 467 | |||
| 466 | Loader::ResultStatus NCA::GetStatus() const { | 468 | Loader::ResultStatus NCA::GetStatus() const { |
| 467 | return status; | 469 | return status; |
| 468 | } | 470 | } |
diff --git a/src/core/file_sys/content_archive.h b/src/core/file_sys/content_archive.h index 00eca52da..f9f66cae9 100644 --- a/src/core/file_sys/content_archive.h +++ b/src/core/file_sys/content_archive.h | |||
| @@ -81,6 +81,8 @@ class NCA : public ReadOnlyVfsDirectory { | |||
| 81 | public: | 81 | public: |
| 82 | explicit NCA(VirtualFile file, VirtualFile bktr_base_romfs = nullptr, | 82 | explicit NCA(VirtualFile file, VirtualFile bktr_base_romfs = nullptr, |
| 83 | u64 bktr_base_ivfc_offset = 0); | 83 | u64 bktr_base_ivfc_offset = 0); |
| 84 | ~NCA() override; | ||
| 85 | |||
| 84 | Loader::ResultStatus GetStatus() const; | 86 | Loader::ResultStatus GetStatus() const; |
| 85 | 87 | ||
| 86 | std::vector<std::shared_ptr<VfsFile>> GetFiles() const override; | 88 | std::vector<std::shared_ptr<VfsFile>> GetFiles() const override; |
diff --git a/src/core/file_sys/control_metadata.cpp b/src/core/file_sys/control_metadata.cpp index e76bf77bf..0c90528a4 100644 --- a/src/core/file_sys/control_metadata.cpp +++ b/src/core/file_sys/control_metadata.cpp | |||
| @@ -20,6 +20,8 @@ NACP::NACP(VirtualFile file) : raw(std::make_unique<RawNACP>()) { | |||
| 20 | file->ReadObject(raw.get()); | 20 | file->ReadObject(raw.get()); |
| 21 | } | 21 | } |
| 22 | 22 | ||
| 23 | NACP::~NACP() = default; | ||
| 24 | |||
| 23 | const LanguageEntry& NACP::GetLanguageEntry(Language language) const { | 25 | const LanguageEntry& NACP::GetLanguageEntry(Language language) const { |
| 24 | if (language != Language::Default) { | 26 | if (language != Language::Default) { |
| 25 | return raw->language_entries.at(static_cast<u8>(language)); | 27 | return raw->language_entries.at(static_cast<u8>(language)); |
diff --git a/src/core/file_sys/control_metadata.h b/src/core/file_sys/control_metadata.h index 8a510bf46..a53654577 100644 --- a/src/core/file_sys/control_metadata.h +++ b/src/core/file_sys/control_metadata.h | |||
| @@ -78,6 +78,8 @@ static constexpr std::array<const char*, 15> LANGUAGE_NAMES = { | |||
| 78 | class NACP { | 78 | class NACP { |
| 79 | public: | 79 | public: |
| 80 | explicit NACP(VirtualFile file); | 80 | explicit NACP(VirtualFile file); |
| 81 | ~NACP(); | ||
| 82 | |||
| 81 | const LanguageEntry& GetLanguageEntry(Language language = Language::Default) const; | 83 | const LanguageEntry& GetLanguageEntry(Language language = Language::Default) const; |
| 82 | std::string GetApplicationName(Language language = Language::Default) const; | 84 | std::string GetApplicationName(Language language = Language::Default) const; |
| 83 | std::string GetDeveloperName(Language language = Language::Default) const; | 85 | std::string GetDeveloperName(Language language = Language::Default) const; |
diff --git a/src/core/file_sys/nca_metadata.cpp b/src/core/file_sys/nca_metadata.cpp index 479916b69..6f34b7836 100644 --- a/src/core/file_sys/nca_metadata.cpp +++ b/src/core/file_sys/nca_metadata.cpp | |||
| @@ -51,6 +51,8 @@ CNMT::CNMT(CNMTHeader header, OptionalHeader opt_header, std::vector<ContentReco | |||
| 51 | : header(std::move(header)), opt_header(std::move(opt_header)), | 51 | : header(std::move(header)), opt_header(std::move(opt_header)), |
| 52 | content_records(std::move(content_records)), meta_records(std::move(meta_records)) {} | 52 | content_records(std::move(content_records)), meta_records(std::move(meta_records)) {} |
| 53 | 53 | ||
| 54 | CNMT::~CNMT() = default; | ||
| 55 | |||
| 54 | u64 CNMT::GetTitleID() const { | 56 | u64 CNMT::GetTitleID() const { |
| 55 | return header.title_id; | 57 | return header.title_id; |
| 56 | } | 58 | } |
diff --git a/src/core/file_sys/nca_metadata.h b/src/core/file_sys/nca_metadata.h index da5a8dbe8..a05d155f4 100644 --- a/src/core/file_sys/nca_metadata.h +++ b/src/core/file_sys/nca_metadata.h | |||
| @@ -87,6 +87,7 @@ public: | |||
| 87 | explicit CNMT(VirtualFile file); | 87 | explicit CNMT(VirtualFile file); |
| 88 | CNMT(CNMTHeader header, OptionalHeader opt_header, std::vector<ContentRecord> content_records, | 88 | CNMT(CNMTHeader header, OptionalHeader opt_header, std::vector<ContentRecord> content_records, |
| 89 | std::vector<MetaRecord> meta_records); | 89 | std::vector<MetaRecord> meta_records); |
| 90 | ~CNMT(); | ||
| 90 | 91 | ||
| 91 | u64 GetTitleID() const; | 92 | u64 GetTitleID() const; |
| 92 | u32 GetTitleVersion() const; | 93 | u32 GetTitleVersion() const; |
diff --git a/src/core/file_sys/partition_filesystem.cpp b/src/core/file_sys/partition_filesystem.cpp index f5b3b0175..5791c76ff 100644 --- a/src/core/file_sys/partition_filesystem.cpp +++ b/src/core/file_sys/partition_filesystem.cpp | |||
| @@ -72,6 +72,8 @@ PartitionFilesystem::PartitionFilesystem(std::shared_ptr<VfsFile> file) { | |||
| 72 | status = Loader::ResultStatus::Success; | 72 | status = Loader::ResultStatus::Success; |
| 73 | } | 73 | } |
| 74 | 74 | ||
| 75 | PartitionFilesystem::~PartitionFilesystem() = default; | ||
| 76 | |||
| 75 | Loader::ResultStatus PartitionFilesystem::GetStatus() const { | 77 | Loader::ResultStatus PartitionFilesystem::GetStatus() const { |
| 76 | return status; | 78 | return status; |
| 77 | } | 79 | } |
diff --git a/src/core/file_sys/partition_filesystem.h b/src/core/file_sys/partition_filesystem.h index e80d2456b..739c63a7f 100644 --- a/src/core/file_sys/partition_filesystem.h +++ b/src/core/file_sys/partition_filesystem.h | |||
| @@ -25,6 +25,8 @@ namespace FileSys { | |||
| 25 | class PartitionFilesystem : public ReadOnlyVfsDirectory { | 25 | class PartitionFilesystem : public ReadOnlyVfsDirectory { |
| 26 | public: | 26 | public: |
| 27 | explicit PartitionFilesystem(std::shared_ptr<VfsFile> file); | 27 | explicit PartitionFilesystem(std::shared_ptr<VfsFile> file); |
| 28 | ~PartitionFilesystem() override; | ||
| 29 | |||
| 28 | Loader::ResultStatus GetStatus() const; | 30 | Loader::ResultStatus GetStatus() const; |
| 29 | 31 | ||
| 30 | std::vector<std::shared_ptr<VfsFile>> GetFiles() const override; | 32 | std::vector<std::shared_ptr<VfsFile>> GetFiles() const override; |
diff --git a/src/core/file_sys/patch_manager.cpp b/src/core/file_sys/patch_manager.cpp index b37b4c68b..aebc69d52 100644 --- a/src/core/file_sys/patch_manager.cpp +++ b/src/core/file_sys/patch_manager.cpp | |||
| @@ -41,6 +41,8 @@ std::string FormatPatchTypeName(PatchType type) { | |||
| 41 | 41 | ||
| 42 | PatchManager::PatchManager(u64 title_id) : title_id(title_id) {} | 42 | PatchManager::PatchManager(u64 title_id) : title_id(title_id) {} |
| 43 | 43 | ||
| 44 | PatchManager::~PatchManager() = default; | ||
| 45 | |||
| 44 | VirtualDir PatchManager::PatchExeFS(VirtualDir exefs) const { | 46 | VirtualDir PatchManager::PatchExeFS(VirtualDir exefs) const { |
| 45 | LOG_INFO(Loader, "Patching ExeFS for title_id={:016X}", title_id); | 47 | LOG_INFO(Loader, "Patching ExeFS for title_id={:016X}", title_id); |
| 46 | 48 | ||
diff --git a/src/core/file_sys/patch_manager.h b/src/core/file_sys/patch_manager.h index b521977b2..209cab1dc 100644 --- a/src/core/file_sys/patch_manager.h +++ b/src/core/file_sys/patch_manager.h | |||
| @@ -34,6 +34,7 @@ std::string FormatPatchTypeName(PatchType type); | |||
| 34 | class PatchManager { | 34 | class PatchManager { |
| 35 | public: | 35 | public: |
| 36 | explicit PatchManager(u64 title_id); | 36 | explicit PatchManager(u64 title_id); |
| 37 | ~PatchManager(); | ||
| 37 | 38 | ||
| 38 | // Currently tracked ExeFS patches: | 39 | // Currently tracked ExeFS patches: |
| 39 | // - Game Updates | 40 | // - Game Updates |
diff --git a/src/core/file_sys/program_metadata.cpp b/src/core/file_sys/program_metadata.cpp index 9d19aaa6d..02319ce0f 100644 --- a/src/core/file_sys/program_metadata.cpp +++ b/src/core/file_sys/program_metadata.cpp | |||
| @@ -12,6 +12,10 @@ | |||
| 12 | 12 | ||
| 13 | namespace FileSys { | 13 | namespace FileSys { |
| 14 | 14 | ||
| 15 | ProgramMetadata::ProgramMetadata() = default; | ||
| 16 | |||
| 17 | ProgramMetadata::~ProgramMetadata() = default; | ||
| 18 | |||
| 15 | Loader::ResultStatus ProgramMetadata::Load(VirtualFile file) { | 19 | Loader::ResultStatus ProgramMetadata::Load(VirtualFile file) { |
| 16 | std::size_t total_size = static_cast<std::size_t>(file->GetSize()); | 20 | std::size_t total_size = static_cast<std::size_t>(file->GetSize()); |
| 17 | if (total_size < sizeof(Header)) | 21 | if (total_size < sizeof(Header)) |
diff --git a/src/core/file_sys/program_metadata.h b/src/core/file_sys/program_metadata.h index 3c0a49f16..1143e36c4 100644 --- a/src/core/file_sys/program_metadata.h +++ b/src/core/file_sys/program_metadata.h | |||
| @@ -36,6 +36,9 @@ enum class ProgramFilePermission : u64 { | |||
| 36 | */ | 36 | */ |
| 37 | class ProgramMetadata { | 37 | class ProgramMetadata { |
| 38 | public: | 38 | public: |
| 39 | ProgramMetadata(); | ||
| 40 | ~ProgramMetadata(); | ||
| 41 | |||
| 39 | Loader::ResultStatus Load(VirtualFile file); | 42 | Loader::ResultStatus Load(VirtualFile file); |
| 40 | 43 | ||
| 41 | bool Is64BitProgram() const; | 44 | bool Is64BitProgram() const; |
diff --git a/src/core/file_sys/romfs_factory.cpp b/src/core/file_sys/romfs_factory.cpp index d9d90939e..3d1a3685e 100644 --- a/src/core/file_sys/romfs_factory.cpp +++ b/src/core/file_sys/romfs_factory.cpp | |||
| @@ -28,6 +28,8 @@ RomFSFactory::RomFSFactory(Loader::AppLoader& app_loader) { | |||
| 28 | ivfc_offset = app_loader.ReadRomFSIVFCOffset(); | 28 | ivfc_offset = app_loader.ReadRomFSIVFCOffset(); |
| 29 | } | 29 | } |
| 30 | 30 | ||
| 31 | RomFSFactory::~RomFSFactory() = default; | ||
| 32 | |||
| 31 | ResultVal<VirtualFile> RomFSFactory::OpenCurrentProcess() { | 33 | ResultVal<VirtualFile> RomFSFactory::OpenCurrentProcess() { |
| 32 | if (!updatable) | 34 | if (!updatable) |
| 33 | return MakeResult<VirtualFile>(file); | 35 | return MakeResult<VirtualFile>(file); |
diff --git a/src/core/file_sys/romfs_factory.h b/src/core/file_sys/romfs_factory.h index 26b8f46cc..2cace8180 100644 --- a/src/core/file_sys/romfs_factory.h +++ b/src/core/file_sys/romfs_factory.h | |||
| @@ -30,6 +30,7 @@ enum class StorageId : u8 { | |||
| 30 | class RomFSFactory { | 30 | class RomFSFactory { |
| 31 | public: | 31 | public: |
| 32 | explicit RomFSFactory(Loader::AppLoader& app_loader); | 32 | explicit RomFSFactory(Loader::AppLoader& app_loader); |
| 33 | ~RomFSFactory(); | ||
| 33 | 34 | ||
| 34 | ResultVal<VirtualFile> OpenCurrentProcess(); | 35 | ResultVal<VirtualFile> OpenCurrentProcess(); |
| 35 | ResultVal<VirtualFile> Open(u64 title_id, StorageId storage, ContentRecordType type); | 36 | ResultVal<VirtualFile> Open(u64 title_id, StorageId storage, ContentRecordType type); |
diff --git a/src/core/file_sys/savedata_factory.cpp b/src/core/file_sys/savedata_factory.cpp index e437d34e5..c092a32cf 100644 --- a/src/core/file_sys/savedata_factory.cpp +++ b/src/core/file_sys/savedata_factory.cpp | |||
| @@ -20,6 +20,8 @@ std::string SaveDataDescriptor::DebugInfo() const { | |||
| 20 | 20 | ||
| 21 | SaveDataFactory::SaveDataFactory(VirtualDir save_directory) : dir(std::move(save_directory)) {} | 21 | SaveDataFactory::SaveDataFactory(VirtualDir save_directory) : dir(std::move(save_directory)) {} |
| 22 | 22 | ||
| 23 | SaveDataFactory::~SaveDataFactory() = default; | ||
| 24 | |||
| 23 | ResultVal<VirtualDir> SaveDataFactory::Open(SaveDataSpaceId space, SaveDataDescriptor meta) { | 25 | ResultVal<VirtualDir> SaveDataFactory::Open(SaveDataSpaceId space, SaveDataDescriptor meta) { |
| 24 | if (meta.type == SaveDataType::SystemSaveData || meta.type == SaveDataType::SaveData) { | 26 | if (meta.type == SaveDataType::SystemSaveData || meta.type == SaveDataType::SaveData) { |
| 25 | if (meta.zero_1 != 0) { | 27 | if (meta.zero_1 != 0) { |
diff --git a/src/core/file_sys/savedata_factory.h b/src/core/file_sys/savedata_factory.h index ba978695b..d69ef6741 100644 --- a/src/core/file_sys/savedata_factory.h +++ b/src/core/file_sys/savedata_factory.h | |||
| @@ -48,6 +48,7 @@ static_assert(sizeof(SaveDataDescriptor) == 0x40, "SaveDataDescriptor has incorr | |||
| 48 | class SaveDataFactory { | 48 | class SaveDataFactory { |
| 49 | public: | 49 | public: |
| 50 | explicit SaveDataFactory(VirtualDir dir); | 50 | explicit SaveDataFactory(VirtualDir dir); |
| 51 | ~SaveDataFactory(); | ||
| 51 | 52 | ||
| 52 | ResultVal<VirtualDir> Open(SaveDataSpaceId space, SaveDataDescriptor meta); | 53 | ResultVal<VirtualDir> Open(SaveDataSpaceId space, SaveDataDescriptor meta); |
| 53 | 54 | ||
diff --git a/src/core/file_sys/submission_package.h b/src/core/file_sys/submission_package.h index 1120a4920..e85a2b76e 100644 --- a/src/core/file_sys/submission_package.h +++ b/src/core/file_sys/submission_package.h | |||
| @@ -24,7 +24,7 @@ enum class ContentRecordType : u8; | |||
| 24 | class NSP : public ReadOnlyVfsDirectory { | 24 | class NSP : public ReadOnlyVfsDirectory { |
| 25 | public: | 25 | public: |
| 26 | explicit NSP(VirtualFile file); | 26 | explicit NSP(VirtualFile file); |
| 27 | ~NSP(); | 27 | ~NSP() override; |
| 28 | 28 | ||
| 29 | Loader::ResultStatus GetStatus() const; | 29 | Loader::ResultStatus GetStatus() const; |
| 30 | Loader::ResultStatus GetProgramStatus(u64 title_id) const; | 30 | Loader::ResultStatus GetProgramStatus(u64 title_id) const; |
diff --git a/src/core/file_sys/vfs_concat.cpp b/src/core/file_sys/vfs_concat.cpp index 25a980cbb..dc7a279a9 100644 --- a/src/core/file_sys/vfs_concat.cpp +++ b/src/core/file_sys/vfs_concat.cpp | |||
| @@ -27,6 +27,8 @@ ConcatenatedVfsFile::ConcatenatedVfsFile(std::vector<VirtualFile> files_, std::s | |||
| 27 | } | 27 | } |
| 28 | } | 28 | } |
| 29 | 29 | ||
| 30 | ConcatenatedVfsFile::~ConcatenatedVfsFile() = default; | ||
| 31 | |||
| 30 | std::string ConcatenatedVfsFile::GetName() const { | 32 | std::string ConcatenatedVfsFile::GetName() const { |
| 31 | if (files.empty()) | 33 | if (files.empty()) |
| 32 | return ""; | 34 | return ""; |
diff --git a/src/core/file_sys/vfs_concat.h b/src/core/file_sys/vfs_concat.h index 31775db7e..717d04bdc 100644 --- a/src/core/file_sys/vfs_concat.h +++ b/src/core/file_sys/vfs_concat.h | |||
| @@ -22,6 +22,8 @@ class ConcatenatedVfsFile : public VfsFile { | |||
| 22 | ConcatenatedVfsFile(std::vector<VirtualFile> files, std::string name); | 22 | ConcatenatedVfsFile(std::vector<VirtualFile> files, std::string name); |
| 23 | 23 | ||
| 24 | public: | 24 | public: |
| 25 | ~ConcatenatedVfsFile() override; | ||
| 26 | |||
| 25 | std::string GetName() const override; | 27 | std::string GetName() const override; |
| 26 | std::size_t GetSize() const override; | 28 | std::size_t GetSize() const override; |
| 27 | bool Resize(std::size_t new_size) override; | 29 | bool Resize(std::size_t new_size) override; |
diff --git a/src/core/file_sys/vfs_offset.cpp b/src/core/file_sys/vfs_offset.cpp index f5ed291ea..a4c6719a0 100644 --- a/src/core/file_sys/vfs_offset.cpp +++ b/src/core/file_sys/vfs_offset.cpp | |||
| @@ -14,6 +14,8 @@ OffsetVfsFile::OffsetVfsFile(std::shared_ptr<VfsFile> file_, std::size_t size_, | |||
| 14 | : file(file_), offset(offset_), size(size_), name(std::move(name_)), | 14 | : file(file_), offset(offset_), size(size_), name(std::move(name_)), |
| 15 | parent(parent_ == nullptr ? file->GetContainingDirectory() : std::move(parent_)) {} | 15 | parent(parent_ == nullptr ? file->GetContainingDirectory() : std::move(parent_)) {} |
| 16 | 16 | ||
| 17 | OffsetVfsFile::~OffsetVfsFile() = default; | ||
| 18 | |||
| 17 | std::string OffsetVfsFile::GetName() const { | 19 | std::string OffsetVfsFile::GetName() const { |
| 18 | return name.empty() ? file->GetName() : name; | 20 | return name.empty() ? file->GetName() : name; |
| 19 | } | 21 | } |
diff --git a/src/core/file_sys/vfs_offset.h b/src/core/file_sys/vfs_offset.h index 34cb180b3..8062702a7 100644 --- a/src/core/file_sys/vfs_offset.h +++ b/src/core/file_sys/vfs_offset.h | |||
| @@ -19,6 +19,7 @@ class OffsetVfsFile : public VfsFile { | |||
| 19 | public: | 19 | public: |
| 20 | OffsetVfsFile(std::shared_ptr<VfsFile> file, std::size_t size, std::size_t offset = 0, | 20 | OffsetVfsFile(std::shared_ptr<VfsFile> file, std::size_t size, std::size_t offset = 0, |
| 21 | std::string new_name = "", VirtualDir new_parent = nullptr); | 21 | std::string new_name = "", VirtualDir new_parent = nullptr); |
| 22 | ~OffsetVfsFile() override; | ||
| 22 | 23 | ||
| 23 | std::string GetName() const override; | 24 | std::string GetName() const override; |
| 24 | std::size_t GetSize() const override; | 25 | std::size_t GetSize() const override; |
diff --git a/src/core/file_sys/vfs_vector.cpp b/src/core/file_sys/vfs_vector.cpp index 98e7c4598..ec7f735b5 100644 --- a/src/core/file_sys/vfs_vector.cpp +++ b/src/core/file_sys/vfs_vector.cpp | |||
| @@ -13,6 +13,8 @@ VectorVfsDirectory::VectorVfsDirectory(std::vector<VirtualFile> files_, | |||
| 13 | : files(std::move(files_)), dirs(std::move(dirs_)), parent(std::move(parent_)), | 13 | : files(std::move(files_)), dirs(std::move(dirs_)), parent(std::move(parent_)), |
| 14 | name(std::move(name_)) {} | 14 | name(std::move(name_)) {} |
| 15 | 15 | ||
| 16 | VectorVfsDirectory::~VectorVfsDirectory() = default; | ||
| 17 | |||
| 16 | std::vector<std::shared_ptr<VfsFile>> VectorVfsDirectory::GetFiles() const { | 18 | std::vector<std::shared_ptr<VfsFile>> VectorVfsDirectory::GetFiles() const { |
| 17 | return files; | 19 | return files; |
| 18 | } | 20 | } |
diff --git a/src/core/file_sys/vfs_vector.h b/src/core/file_sys/vfs_vector.h index 179f62e4b..cba44a7a6 100644 --- a/src/core/file_sys/vfs_vector.h +++ b/src/core/file_sys/vfs_vector.h | |||
| @@ -15,6 +15,7 @@ public: | |||
| 15 | explicit VectorVfsDirectory(std::vector<VirtualFile> files = {}, | 15 | explicit VectorVfsDirectory(std::vector<VirtualFile> files = {}, |
| 16 | std::vector<VirtualDir> dirs = {}, std::string name = "", | 16 | std::vector<VirtualDir> dirs = {}, std::string name = "", |
| 17 | VirtualDir parent = nullptr); | 17 | VirtualDir parent = nullptr); |
| 18 | ~VectorVfsDirectory() override; | ||
| 18 | 19 | ||
| 19 | std::vector<std::shared_ptr<VfsFile>> GetFiles() const override; | 20 | std::vector<std::shared_ptr<VfsFile>> GetFiles() const override; |
| 20 | std::vector<std::shared_ptr<VfsDirectory>> GetSubdirectories() const override; | 21 | std::vector<std::shared_ptr<VfsDirectory>> GetSubdirectories() const override; |
diff --git a/src/core/file_sys/xts_archive.cpp b/src/core/file_sys/xts_archive.cpp index 0173f71c1..b53f81947 100644 --- a/src/core/file_sys/xts_archive.cpp +++ b/src/core/file_sys/xts_archive.cpp | |||
| @@ -72,6 +72,8 @@ NAX::NAX(VirtualFile file_, std::array<u8, 0x10> nca_id) | |||
| 72 | Common::HexArrayToString(nca_id, false))); | 72 | Common::HexArrayToString(nca_id, false))); |
| 73 | } | 73 | } |
| 74 | 74 | ||
| 75 | NAX::~NAX() = default; | ||
| 76 | |||
| 75 | Loader::ResultStatus NAX::Parse(std::string_view path) { | 77 | Loader::ResultStatus NAX::Parse(std::string_view path) { |
| 76 | if (file->ReadObject(header.get()) != sizeof(NAXHeader)) | 78 | if (file->ReadObject(header.get()) != sizeof(NAXHeader)) |
| 77 | return Loader::ResultStatus::ErrorBadNAXHeader; | 79 | return Loader::ResultStatus::ErrorBadNAXHeader; |
diff --git a/src/core/file_sys/xts_archive.h b/src/core/file_sys/xts_archive.h index 55d2154a6..9e3068069 100644 --- a/src/core/file_sys/xts_archive.h +++ b/src/core/file_sys/xts_archive.h | |||
| @@ -33,6 +33,7 @@ class NAX : public ReadOnlyVfsDirectory { | |||
| 33 | public: | 33 | public: |
| 34 | explicit NAX(VirtualFile file); | 34 | explicit NAX(VirtualFile file); |
| 35 | explicit NAX(VirtualFile file, std::array<u8, 0x10> nca_id); | 35 | explicit NAX(VirtualFile file, std::array<u8, 0x10> nca_id); |
| 36 | ~NAX() override; | ||
| 36 | 37 | ||
| 37 | Loader::ResultStatus GetStatus() const; | 38 | Loader::ResultStatus GetStatus() const; |
| 38 | 39 | ||