mirror of
https://github.com/trezor/trezor-firmware.git
synced 2024-12-17 20:08:12 +00:00
fix(python): do not call EndSession in bootloader mode (fixes #1379)
This commit is contained in:
parent
48024de685
commit
4d4d0e7216
@ -398,10 +398,13 @@ class TrezorClient:
|
||||
|
||||
The session will become invalid until `init_device()` is called again.
|
||||
If passphrase is enabled, further actions will prompt for it again.
|
||||
|
||||
This is a no-op in bootloader mode, as it does not support session management.
|
||||
"""
|
||||
# since: 2.3.4, 1.9.4
|
||||
try:
|
||||
self.call(messages.EndSession())
|
||||
if not self.features.bootloader_mode:
|
||||
self.call(messages.EndSession())
|
||||
except exceptions.TrezorFailure:
|
||||
# A failure most likely means that the FW version does not support
|
||||
# the EndSession call. We ignore the failure and clear the local session_id.
|
||||
|
Loading…
Reference in New Issue
Block a user