diff --git a/src/fenrirscreenreader/inputDriver/evdevDriver.py b/src/fenrirscreenreader/inputDriver/evdevDriver.py index 54ca4809..6aa5a6b5 100644 --- a/src/fenrirscreenreader/inputDriver/evdevDriver.py +++ b/src/fenrirscreenreader/inputDriver/evdevDriver.py @@ -182,7 +182,8 @@ class driver(inputDriver): continue self.env['runtime']['debug'].writeDebugOut('open(deviceFile)',debug.debugLevel.ERROR) try: - open(deviceFile) + with open(deviceFile) as f: + pass except Exception as e: self.env['runtime']['debug'].writeDebugOut("Not readable Inputdevice : " + deviceFile +' ' + str(e),debug.debugLevel.ERROR) continue