diff options
| -rw-r--r-- | apt/progress/__init__.py | 17 | ||||
| -rw-r--r-- | debian/changelog | 7 |
2 files changed, 20 insertions, 4 deletions
diff --git a/apt/progress/__init__.py b/apt/progress/__init__.py index 3be197f7..b582ad22 100644 --- a/apt/progress/__init__.py +++ b/apt/progress/__init__.py @@ -286,11 +286,20 @@ class InstallProgress(DumbInstallProgress): def waitChild(self): """Wait for child progress to exit.""" while True: - select.select([self.statusfd], [], [], self.selectTimeout) - self.updateInterface() - (pid, res) = os.waitpid(self.child_pid, os.WNOHANG) - if pid == self.child_pid: + try: + select.select([self.statusfd], [], [], self.selectTimeout) + except select.error, (errno_, errstr): + if errno_ != errno.EINTR: + raise break + self.updateInterface() + try: + (pid, res) = os.waitpid(self.child_pid, os.WNOHANG) + if pid == self.child_pid: + break + except OSError, (errno_, errstr): + if errno_ != errno.EINTR: + raise return res def run(self, pm): diff --git a/debian/changelog b/debian/changelog index c7016fc5..5a5b7529 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,10 @@ +python-apt (0.7.11.1) UNRELEASED; urgency=low + + * apt/progress/__init__.py: + - Exception handling fixes in InstallProgress class. + + -- Stephan Peijnik <debian@sp.or.at> Sat, 25 Jul 2009 10:37:11 +0200 + python-apt (0.7.11.0) unstable; urgency=low [ Julian Andres Klode ] |
