issue #174: select.error interface differs to OSError

Only OSError got the magical attribute treatment, select.error still
behaves like a tuple.
pull/175/head
David Wilson 7 years ago
parent ffdd192397
commit fa271fcc8e

@ -216,9 +216,9 @@ def io_op(func, *args):
return func(*args), False
except (select.error, OSError), e:
_vv and IOLOG.debug('io_op(%r) -> OSError: %s', func, e)
if e.errno == errno.EINTR:
if e[0] == errno.EINTR:
continue
if e.errno in (errno.EIO, errno.ECONNRESET, errno.EPIPE):
if e[0] in (errno.EIO, errno.ECONNRESET, errno.EPIPE):
return None, True
raise

Loading…
Cancel
Save