diff options
author | Rafael H. Schloming <rhs@apache.org> | 2010-03-23 20:34:58 +0000 |
---|---|---|
committer | Rafael H. Schloming <rhs@apache.org> | 2010-03-23 20:34:58 +0000 |
commit | 7cfa62f6187ddecfdf7149cc501778b66d8cfcc8 (patch) | |
tree | 182e61f704191fb5471b6a1cd316bda5c426b2e1 /python/qpid/messaging/endpoints.py | |
parent | 858769adbb30ff616f39f20c9ecc1a0bd3349205 (diff) | |
download | qpid-python-7cfa62f6187ddecfdf7149cc501778b66d8cfcc8.tar.gz |
fixed resource leakage on repeated connection open/close
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@926766 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'python/qpid/messaging/endpoints.py')
-rw-r--r-- | python/qpid/messaging/endpoints.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/python/qpid/messaging/endpoints.py b/python/qpid/messaging/endpoints.py index af2b1a8007..195c6e7ef7 100644 --- a/python/qpid/messaging/endpoints.py +++ b/python/qpid/messaging/endpoints.py @@ -102,7 +102,6 @@ class Connection: self.error = None from driver import Driver self._driver = Driver(self) - self._driver.start() def _wait(self, predicate, timeout=None): return self._waiter.wait(predicate, timeout=timeout) @@ -157,6 +156,7 @@ class Connection: Connect to the remote endpoint. """ self._connected = True + self._driver.start() self._wakeup() self._ewait(lambda: self._transport_connected and not self._unlinked(), exc=ConnectError) @@ -175,6 +175,8 @@ class Connection: self._connected = False self._wakeup() self._ewait(lambda: not self._transport_connected) + self._driver.stop() + self._condition.gc() @synchronized def connected(self): |