diff options
Diffstat (limited to 'pym/_emerge/__init__.py')
-rw-r--r-- | pym/_emerge/__init__.py | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/pym/_emerge/__init__.py b/pym/_emerge/__init__.py index d25358faa..0665701f7 100644 --- a/pym/_emerge/__init__.py +++ b/pym/_emerge/__init__.py @@ -1467,6 +1467,8 @@ class AsynchronousTask(SlotObject): return self.returncode is None def poll(self): + if self.returncode is not None: + self._wait_hook() return self.returncode def wait(self): @@ -1474,7 +1476,8 @@ class AsynchronousTask(SlotObject): return self.returncode def cancel(self): - pass + self.cancelled = True + self.wait() def addExitListener(self, f): """ @@ -2619,12 +2622,6 @@ class BinpkgVerifier(AsynchronousTask): self.returncode = rval - def cancel(self): - self.cancelled = True - - def poll(self): - return self.returncode - class BinpkgExtractorAsync(SpawnProcess): __slots__ = ("image_dir", "pkg", "pkg_path") |