From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id 4A8A1138010 for ; Wed, 3 Oct 2012 18:39:43 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id B9258E0028; Wed, 3 Oct 2012 18:39:34 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id 81807E0028 for ; Wed, 3 Oct 2012 18:39:34 +0000 (UTC) Received: from hornbill.gentoo.org (hornbill.gentoo.org [94.100.119.163]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id B3182335E30 for ; Wed, 3 Oct 2012 18:39:33 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by hornbill.gentoo.org (Postfix) with ESMTP id 59CA2E5436 for ; Wed, 3 Oct 2012 18:39:32 +0000 (UTC) From: "Zac Medico" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Zac Medico" Message-ID: <1349289551.3453c38128c8af3e0178dce7d2d64d7cfb899141.zmedico@gentoo> Subject: [gentoo-commits] proj/portage:master commit in: pym/portage/util/_async/ X-VCS-Repository: proj/portage X-VCS-Files: pym/portage/util/_async/AsyncScheduler.py X-VCS-Directories: pym/portage/util/_async/ X-VCS-Committer: zmedico X-VCS-Committer-Name: Zac Medico X-VCS-Revision: 3453c38128c8af3e0178dce7d2d64d7cfb899141 X-VCS-Branch: master Date: Wed, 3 Oct 2012 18:39:32 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: 3cd8341c-79b4-4025-a8d1-5f1a8235428d X-Archives-Hash: 401f1a2d3dfe82248b78f2be0fe361f3 commit: 3453c38128c8af3e0178dce7d2d64d7cfb899141 Author: Zac Medico gentoo org> AuthorDate: Wed Oct 3 18:39:11 2012 +0000 Commit: Zac Medico gentoo org> CommitDate: Wed Oct 3 18:39:11 2012 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/portage.git;a=commit;h=3453c381 AsyncScheduler: implement _poll --- pym/portage/util/_async/AsyncScheduler.py | 5 +++++ 1 files changed, 5 insertions(+), 0 deletions(-) diff --git a/pym/portage/util/_async/AsyncScheduler.py b/pym/portage/util/_async/AsyncScheduler.py index a452c0c..3fb079c 100644 --- a/pym/portage/util/_async/AsyncScheduler.py +++ b/pym/portage/util/_async/AsyncScheduler.py @@ -25,6 +25,11 @@ class AsyncScheduler(AsynchronousTask, PollScheduler): self._term_check_id = None self._loadavg_check_id = None + def _poll(self): + if not (self._is_work_scheduled() or self._keep_scheduling()): + self.wait() + return self.returncode + def _cancel(self): self._terminated.set() self._termination_check()