mirror of
https://github.com/trezor/trezor-firmware.git
synced 2025-02-17 01:52:02 +00:00
recovery: don't reset storage on typos during dry-run recovery
This commit is contained in:
parent
a9a414df08
commit
ace1d84265
@ -450,7 +450,9 @@ static void recovery_scrambledword(const char *word)
|
|||||||
{
|
{
|
||||||
if (word_pos == 0) { // fake word
|
if (word_pos == 0) { // fake word
|
||||||
if (strcmp(word, fake_word) != 0) {
|
if (strcmp(word, fake_word) != 0) {
|
||||||
storage_reset();
|
if (!dry_run) {
|
||||||
|
storage_reset();
|
||||||
|
}
|
||||||
fsm_sendFailure(FailureType_Failure_ProcessError, _("Wrong word retyped"));
|
fsm_sendFailure(FailureType_Failure_ProcessError, _("Wrong word retyped"));
|
||||||
layoutHome();
|
layoutHome();
|
||||||
return;
|
return;
|
||||||
@ -467,7 +469,9 @@ static void recovery_scrambledword(const char *word)
|
|||||||
wl++;
|
wl++;
|
||||||
}
|
}
|
||||||
if (!found) {
|
if (!found) {
|
||||||
storage_reset();
|
if (!dry_run) {
|
||||||
|
storage_reset();
|
||||||
|
}
|
||||||
fsm_sendFailure(FailureType_Failure_DataError, _("Word not found in a wordlist"));
|
fsm_sendFailure(FailureType_Failure_DataError, _("Word not found in a wordlist"));
|
||||||
layoutHome();
|
layoutHome();
|
||||||
return;
|
return;
|
||||||
|
Loading…
Reference in New Issue
Block a user