On pypy3 IOError is not OSError

This commit is contained in:
Randall Leeds 2015-07-13 14:32:01 -07:00
parent c054bddd1a
commit ec84c80c75

View File

@ -381,7 +381,7 @@ class ScalableSelectorMixIn:
for i in range(NUM_FDS // 2):
try:
rd, wr = self.make_socketpair()
except OSError:
except (IOError, OSError):
# too many FDs, skip - note that we should only catch EMFILE
# here, but apparently *BSD and Solaris can fail upon connect()
# or bind() with EADDRNOTAVAIL, so let's be safe