mirror of
https://github.com/python/cpython.git
synced 2025-08-04 00:48:58 +00:00
Issue #16706: get rid of os.error
This commit is contained in:
parent
a191959849
commit
ad28c7f9da
33 changed files with 4089 additions and 4123 deletions
|
@ -1444,7 +1444,7 @@ class Popen(object):
|
|||
|
||||
|
||||
def _internal_poll(self, _deadstate=None, _waitpid=os.waitpid,
|
||||
_WNOHANG=os.WNOHANG, _os_error=os.error):
|
||||
_WNOHANG=os.WNOHANG):
|
||||
"""Check if child process has terminated. Returns returncode
|
||||
attribute.
|
||||
|
||||
|
@ -1457,7 +1457,7 @@ class Popen(object):
|
|||
pid, sts = _waitpid(self.pid, _WNOHANG)
|
||||
if pid == self.pid:
|
||||
self._handle_exitstatus(sts)
|
||||
except _os_error as e:
|
||||
except OSError as e:
|
||||
if _deadstate is not None:
|
||||
self.returncode = _deadstate
|
||||
elif e.errno == errno.ECHILD:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue