diff options
Diffstat (limited to 'src/core/loader/nsp.cpp')
-rw-r--r-- | src/core/loader/nsp.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/core/loader/nsp.cpp b/src/core/loader/nsp.cpp index 4d4b44571..7fcb12aa2 100644 --- a/src/core/loader/nsp.cpp +++ b/src/core/loader/nsp.cpp @@ -158,4 +158,12 @@ ResultStatus AppLoader_NSP::ReadControlData(FileSys::NACP& nacp) { nacp = *nacp_file; return ResultStatus::Success; } + +ResultStatus AppLoader_NSP::ReadManualRomFS(FileSys::VirtualFile& file) { + const auto nca = nsp->GetNCA(nsp->GetProgramTitleID(), FileSys::ContentRecordType::Manual); + if (nsp->GetStatus() != ResultStatus::Success || nca == nullptr) + return ResultStatus::ErrorNoRomFS; + file = nca->GetRomFS(); + return file == nullptr ? ResultStatus::ErrorNoRomFS : ResultStatus::Success; +} } // namespace Loader |