mirror of https://github.com/python/cpython
Merge 3.3.
This commit is contained in:
commit
c346060440
|
@ -47,7 +47,7 @@ class Popen(object):
|
|||
def wait(self, timeout=None):
|
||||
if self.returncode is None:
|
||||
if timeout is not None:
|
||||
from .connection import wait
|
||||
from multiprocessing.connection import wait
|
||||
if not wait([self.sentinel], timeout):
|
||||
return None
|
||||
# This shouldn't block if wait() returned successfully.
|
||||
|
|
|
@ -57,7 +57,7 @@ class Popen(popen_fork.Popen):
|
|||
|
||||
def poll(self, flag=os.WNOHANG):
|
||||
if self.returncode is None:
|
||||
from .connection import wait
|
||||
from multiprocessing.connection import wait
|
||||
timeout = 0 if flag == os.WNOHANG else None
|
||||
if not wait([self.sentinel], timeout):
|
||||
return None
|
||||
|
|
Loading…
Reference in New Issue