diff --git a/src/core/fs/archive_ncch.cpp b/src/core/fs/archive_ncch.cpp index d7dd1f57..db6ee337 100644 --- a/src/core/fs/archive_ncch.cpp +++ b/src/core/fs/archive_ncch.cpp @@ -75,6 +75,7 @@ std::optional NCCHArchive::readFile(FileSession* file, u64 offset, u32 size const u32 highProgramID = *(u32*)&archivePath[4]; // High Title ID of the archive (from Citra). https://3dbrew.org/wiki/Title_list. + constexpr u32 systemApplication = 0x00040010; constexpr u32 sharedDataArchive = 0x0004009B; constexpr u32 systemDataArchive = 0x000400DB; @@ -85,7 +86,9 @@ std::optional NCCHArchive::readFile(FileSession* file, u64 offset, u32 size constexpr u32 sharedFont = 0x00014002; std::vector fileData; - if (highProgramID == sharedDataArchive) { + if (highProgramID == systemApplication) { + Helpers::panic("[NCCH archive] Read from system application. ID: %08X", lowProgramID); + } else if (highProgramID == sharedDataArchive) { if (lowProgramID == miiData) fileData = std::vector(std::begin(MII_DATA), std::end(MII_DATA)); else if (lowProgramID == regionManifest) fileData = std::vector(std::begin(COUNTRY_LIST_DATA), std::end(COUNTRY_LIST_DATA)); else Helpers::panic("[NCCH archive] Read unimplemented NAND file. ID: %08X", lowProgramID);