ssnet: EHOSTUNREACH and ENETUNREACH are non-fatal errors.

Reported by Wayne Scott.
This commit is contained in:
Avery Pennarun 2010-05-07 12:30:03 -04:00
parent 8fe3592be3
commit 77935bd110

View File

@ -83,7 +83,9 @@ class SockWrapper:
elif e.args[0] == errno.EISCONN: elif e.args[0] == errno.EISCONN:
# connected successfully (BSD) # connected successfully (BSD)
self.connect_to = None self.connect_to = None
elif e.args[0] in [errno.ECONNREFUSED, errno.ETIMEDOUT]: elif e.args[0] in [errno.ECONNREFUSED, errno.ETIMEDOUT,
errno.EHOSTUNREACH, errno.ENETUNREACH,
errno.EACCES, errno.EPERM]:
# a "normal" kind of error # a "normal" kind of error
self.connect_to = None self.connect_to = None
self.seterr(e) self.seterr(e)