Use ErrorEncrypted where applicable and fix no keys crash

This commit is contained in:
Zach Hilman 2018-07-29 20:47:33 -04:00
parent 03149d3e4a
commit a9c921a41d
4 changed files with 36 additions and 16 deletions

View file

@ -48,6 +48,10 @@ ResultStatus AppLoader_XCI::Load(Kernel::SharedPtr<Kernel::Process>& process) {
return ResultStatus::ErrorAlreadyLoaded;
}
if (xci->GetNCAFileByType(FileSys::NCAContentType::Program) == nullptr) {
return ResultStatus::ErrorEncrypted;
}
auto result = nca_loader->Load(process);
if (result != ResultStatus::Success)
return result;