diff --git a/ptyprocess/ptyprocess.py b/ptyprocess/ptyprocess.py index daf20b1..0b08327 100644 --- a/ptyprocess/ptyprocess.py +++ b/ptyprocess/ptyprocess.py @@ -336,7 +336,7 @@ def spawn( exception = exctype(errmsg.decode('utf-8', 'replace')) if exctype is OSError: exception.errno = int(errno_s) - except: + except Exception: raise Exception('Subprocess failed, got bad error data: %r' % exec_err_data) else: @@ -388,7 +388,7 @@ def __del__(self): try: self.close() # which exception, shouldn't we catch explicitly .. ? - except: + except Exception: pass