diff options
| author | Michael Goulish <mgoulish@apache.org> | 2012-01-25 20:20:28 +0000 |
|---|---|---|
| committer | Michael Goulish <mgoulish@apache.org> | 2012-01-25 20:20:28 +0000 |
| commit | c42e092b4e665508237f13f17dec8f2f6e884679 (patch) | |
| tree | 719b2706d16870850c366725edc9cce1b543ed08 /python | |
| parent | 023ad6169f3f61c0250b8bbd11c7dd4469f11031 (diff) | |
| download | qpid-python-c42e092b4e665508237f13f17dec8f2f6e884679.tar.gz | |
Backing out change from rev 1235255.
This change broke these two tests:
qpid.tests.connection.ConnectionTest.testCloseGet
qpid.tests.connection.ConnectionTest.testCloseListen
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1235906 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'python')
| -rw-r--r-- | python/qpid/connection.py | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/python/qpid/connection.py b/python/qpid/connection.py index 53b7d8ff7e..7dbefb8778 100644 --- a/python/qpid/connection.py +++ b/python/qpid/connection.py @@ -161,12 +161,9 @@ class Connection(Framer): data = self.sock.recv(64*1024) if self.security_layer_rx and data: status, data = self.security_layer_rx.decode(data) - # zero-length data is OK, as long as return code is good. - # when that happens, just keep trying. the sasl library - # will send us data eventually. ( or an error code. ) - if not status: - self.detach_all() - break + if not data: + self.detach_all() + break except socket.timeout: if self.aborted(): self.close_code = (None, "connection timed out") |
