From 7320a093a4fd08f2330d65f40440bbbbfb3f4b7e Mon Sep 17 00:00:00 2001 From: lxnay Date: Thu, 31 Jul 2008 08:33:55 +0000 Subject: [PATCH] Entropy/EntropyRepositorySocketClientCommands: - on convert_stream_to_object() handle zlib errors too git-svn-id: http://svn.sabayonlinux.org/projects/entropy/trunk@2316 cd1c1023-2f26-0410-ae45-c471fc1f0318 --- libraries/entropy.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libraries/entropy.py b/libraries/entropy.py index ea65156d3..a272732d1 100644 --- a/libraries/entropy.py +++ b/libraries/entropy.py @@ -19373,7 +19373,7 @@ class EntropySocketClientCommands: class EntropyRepositorySocketClientCommands(EntropySocketClientCommands): - import entropyTools, socket, struct + import entropyTools, socket, struct, zlib def __init__(self, EntropyInterface, ServiceInterface): if not isinstance(EntropyInterface, (EquoInterface, ServerInterface)) and \ @@ -19490,7 +19490,7 @@ class EntropyRepositorySocketClientCommands(EntropySocketClientCommands): error = False try: data = self.Service.stream_to_object(data, gzipped) - except (EOFError,IOError,): + except (EOFError,IOError,self.zlib.error,): mytxt = _("cannot convert stream into object") self.Entropy.updateProgress( "[%s:%s|%s:%s|%s:%s] %s" % (