1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2024-12-23 14:58:09 +00:00

fix(core): stay_in_bootloader should default to false, not true

This commit is contained in:
Pavol Rusnak 2021-03-06 20:09:56 +01:00
parent efac5d56f5
commit ebfd51d818
No known key found for this signature in database
GPG Key ID: 91F3B339B9A02A3D

View File

@ -260,7 +260,7 @@ int main(void) {
vendor_header vhdr;
image_header hdr;
secbool stay_in_bootloader = sectrue; // flag to stay in bootloader
secbool stay_in_bootloader = secfalse; // flag to stay in bootloader
// detect whether the devices contains a valid firmware
@ -308,7 +308,8 @@ int main(void) {
if (bootloader_usb_loop(NULL, NULL) != sectrue) {
return 1;
}
} else {
}
// ... or if user touched the screen on start
// ... or we have stay_in_bootloader flag to force it
if (touched || stay_in_bootloader == sectrue) {
@ -321,7 +322,6 @@ int main(void) {
return 1;
}
}
}
ensure(load_vendor_header_keys((const uint8_t *)FIRMWARE_START, &vhdr),
"invalid vendor header");