tfollow-up prev - electrum - Electrum Bitcoin wallet HTML git clone https://git.parazyd.org/electrum DIR Log DIR Files DIR Refs DIR Submodules --- DIR commit 1ec71cbacafe63a50cdbfadd3ba8c5f2cfc4786a DIR parent 7d844096285e8ddb4a663d94b2e44665b0e7be7a HTML Author: SomberNight <somber.night@protonmail.com> Date: Tue, 4 Sep 2018 16:42:08 +0200 follow-up prev fix #4078 Diffstat: M electrum/qrscanner.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) --- DIR diff --git a/electrum/qrscanner.py b/electrum/qrscanner.py t@@ -74,10 +74,11 @@ def _find_system_cameras(): devices = {} # Name -> device if os.path.exists(device_root): for device in os.listdir(device_root): + path = os.path.join(device_root, device, 'name') try: - with open(os.path.join(device_root, device, 'name'), encoding='utf-8') as f: + with open(path, encoding='utf-8') as f: name = f.read() - except IOError: + except Exception: continue name = name.strip('\n') devices[name] = os.path.join("/dev", device)