tkivy: fix potential crash in on_resume - electrum - Electrum Bitcoin wallet HTML git clone https://git.parazyd.org/electrum DIR Log DIR Files DIR Refs DIR Submodules --- DIR commit 1d4ca34ca698079151aa68915f8bd3bf0c11e3cc DIR parent cad8e29ed778cc53480bfecfa0acfcac4c210535 HTML Author: SomberNight <somber.night@protonmail.com> Date: Fri, 8 Jun 2018 20:29:07 +0200 kivy: fix potential crash in on_resume happened for me at least once, but for some reason kivy actually "ignored the exception", and simply printed a long trace into logcat, starting with: WARNING:kivy:stderr: Exception ignored in: 'kivy.core.window._window_sdl2._WindowSDL2Storage.cb_event_filter' Diffstat: M gui/kivy/main_window.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- DIR diff --git a/gui/kivy/main_window.py b/gui/kivy/main_window.py t@@ -709,7 +709,7 @@ class ElectrumWindow(App): def on_resume(self): now = time.time() - if self.wallet.has_password and now - self.pause_time > 60: + if self.wallet and self.wallet.has_password and now - self.pause_time > 60: self.password_dialog(self.wallet, _('Enter PIN'), None, self.stop) if self.nfcscanner: self.nfcscanner.nfc_enable()