From f6113b7fa9c2802d56a5fb8fff856ef26f693485 Mon Sep 17 00:00:00 2001 From: Scott Petersen Date: Fri, 21 Feb 2014 12:54:00 -0800 Subject: [PATCH] Added missing potential exception when opening a SerialDevice. --- alarmdecoder/devices.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/alarmdecoder/devices.py b/alarmdecoder/devices.py index cb113cc..d2edffe 100644 --- a/alarmdecoder/devices.py +++ b/alarmdecoder/devices.py @@ -665,8 +665,8 @@ class SerialDevice(Device): # all issues with it. self._device.baudrate = baudrate - except (serial.SerialException, ValueError), err: - raise NoDeviceError('Error opening device on port {0}.'.format(self._port), err) + except (serial.SerialException, ValueError, OSError), err: + raise NoDeviceError('Error opening device on {0}.'.format(self._port), err) else: self._running = True