mirror of
https://github.com/Atmosphere-NX/Atmosphere
synced 2024-11-09 22:56:35 +00:00
loader: correct anti-downgrade tables for new version scheme
This commit is contained in:
parent
0e289461bb
commit
17b6bcfd37
1 changed files with 14 additions and 21 deletions
|
@ -94,27 +94,20 @@ namespace ams::ldr {
|
|||
#ifdef LDR_VALIDATE_PROCESS_VERSION
|
||||
const MinimumProgramVersion *entries = nullptr;
|
||||
size_t num_entries = 0;
|
||||
switch (hos::GetVersion()) {
|
||||
case hos::Version_8_1_0:
|
||||
entries = g_MinimumProgramVersions810;
|
||||
num_entries = g_MinimumProgramVersionsCount810;
|
||||
break;
|
||||
case hos::Version_9_0_0:
|
||||
entries = g_MinimumProgramVersions900;
|
||||
num_entries = g_MinimumProgramVersionsCount900;
|
||||
break;
|
||||
case hos::Version_9_1_0:
|
||||
entries = g_MinimumProgramVersions910;
|
||||
num_entries = g_MinimumProgramVersionsCount910;
|
||||
break;
|
||||
case hos::Version_10_0_0:
|
||||
|
||||
const auto hos_version = hos::GetVersion();
|
||||
if (hos_version >= hos::Version_10_0_0) {
|
||||
entries = g_MinimumProgramVersions1000;
|
||||
num_entries = g_MinimumProgramVersionsCount1000;
|
||||
break;
|
||||
default:
|
||||
entries = nullptr;
|
||||
num_entries = 0;
|
||||
break;
|
||||
} else if (hos_version >= hos::Version_9_1_0) {
|
||||
entries = g_MinimumProgramVersions910;
|
||||
num_entries = g_MinimumProgramVersionsCount910;
|
||||
} else if (hos_version >= hos::Version_9_0_0) {
|
||||
entries = g_MinimumProgramVersions900;
|
||||
num_entries = g_MinimumProgramVersionsCount900;
|
||||
} else if (hos_version >= hos::Version_8_1_0) {
|
||||
entries = g_MinimumProgramVersions810;
|
||||
num_entries = g_MinimumProgramVersionsCount810;
|
||||
}
|
||||
|
||||
for (size_t i = 0; i < num_entries; i++) {
|
||||
|
|
Loading…
Reference in a new issue