1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2024-11-29 10:58:21 +00:00

chore(core): catch possible EOFError when parsing translations header

[no changelog]
This commit is contained in:
grdddj 2024-02-13 10:08:42 +01:00 committed by Jiří Musil
parent f234d19992
commit 5ce5d47171

View File

@ -70,7 +70,7 @@ async def do_change_language(
header_data = await _get_data_chunk(data_length, 0)
try:
header = translations.TranslationsHeader(header_data)
except ValueError:
except (ValueError, EOFError):
raise DataError("Invalid translations data")
# Verifying header information