Use InterruptedError instead of checking for EINTR

This commit is contained in:
Antoine Pitrou 2011-10-23 23:49:42 +02:00
parent dcbb822c08
commit 24d659daaf
6 changed files with 17 additions and 38 deletions

View file

@ -450,10 +450,8 @@ def _eintr_retry_call(func, *args):
while True:
try:
return func(*args)
except (OSError, IOError) as e:
if e.errno == errno.EINTR:
continue
raise
except InterruptedError:
continue
def call(*popenargs, timeout=None, **kwargs):