mirror of
https://github.com/Atmosphere-NX/Atmosphere.git
synced 2025-05-27 21:24:11 -04:00
Daybreak: support installing non-exfat update if only exfat firm is missing/corrupt
This commit is contained in:
parent
65b42497d7
commit
3d2eb8e903
4 changed files with 51 additions and 24 deletions
|
@ -814,6 +814,19 @@ namespace dbk {
|
|||
if (R_SUCCEEDED(m_validation_info.result)) {
|
||||
this->LogText("Update is valid!\n");
|
||||
|
||||
if (R_FAILED(m_validation_info.exfat_result)) {
|
||||
const u32 version = m_validation_info.invalid_key.version;
|
||||
this->LogText("exFAT Validation failed with result: 0x%08x\n", m_validation_info.exfat_result);
|
||||
this->LogText("Missing content:\n- Program id: %016lx\n- Version: %d.%d.%d\n", m_validation_info.invalid_key.id, (version >> 26) & 0x1f, (version >> 20) & 0x1f, (version >> 16) & 0xf);
|
||||
|
||||
/* Log the missing content id. */
|
||||
this->LogText("- Content id: ");
|
||||
for (size_t i = 0; i < sizeof(NcmContentId); i++) {
|
||||
this->LogText("%02x", m_validation_info.invalid_content_id.c[i]);
|
||||
}
|
||||
this->LogText("\n");
|
||||
}
|
||||
|
||||
/* Enable the back and continue buttons and select the continue button. */
|
||||
this->SetButtonEnabled(BackButtonId, true);
|
||||
this->SetButtonEnabled(ContinueButtonId, true);
|
||||
|
@ -867,12 +880,18 @@ namespace dbk {
|
|||
}
|
||||
|
||||
/* Check if exfat is supported. */
|
||||
g_exfat_supported = m_update_info.exfat_supported;
|
||||
g_exfat_supported = m_update_info.exfat_supported && R_SUCCEEDED(m_validation_info.exfat_result);
|
||||
if (!g_exfat_supported) {
|
||||
g_use_exfat = false;
|
||||
}
|
||||
|
||||
ChangeMenu(std::make_shared<ChooseResetMenu>(g_current_menu));
|
||||
/* Warn the user if they're updating with exFAT supposed to be supported but not present/corrupted. */
|
||||
if (m_update_info.exfat_supported && R_FAILED(m_validation_info.exfat_result)) {
|
||||
ChangeMenu(std::make_shared<WarningMenu>(g_current_menu, std::make_shared<ChooseResetMenu>(g_current_menu), "Warning: exFAT firmware is missing or corrupt", "Are you sure you want to proceed?"));
|
||||
} else {
|
||||
ChangeMenu(std::make_shared<ChooseResetMenu>(g_current_menu));
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue