unix: fix exception catch on 3.x.

issue260
David Wilson 6 years ago
parent 0864155592
commit f343bbba3a

@ -52,7 +52,7 @@ def is_path_dead(path):
s.connect(path) s.connect(path)
except socket.error: except socket.error:
e = sys.exc_info()[1] e = sys.exc_info()[1]
return e[0] in (errno.ECONNREFUSED, errno.ENOENT) return e.args[0] in (errno.ECONNREFUSED, errno.ENOENT)
return False return False

Loading…
Cancel
Save