Old exception handling format to new one

This commit is contained in:
Miroslav Stampar
2019-01-22 14:09:13 +01:00
parent ba356baab0
commit bdc4457f34
11 changed files with 26 additions and 27 deletions

View File

@@ -180,7 +180,7 @@ class AnsiToWin32(object):
def _write(self, text, retry=5):
try:
self.wrapped.write(text)
except IOError, err:
except IOError as err:
if not (err.errno == 0 and retry > 0):
raise
self._write(text, retry-1)