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/concurrency.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/concurrency.py')
-rw-r--r-- | python/qpid/concurrency.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/python/qpid/concurrency.py b/python/qpid/concurrency.py index 9837a3f0df..eefe0d445f 100644 --- a/python/qpid/concurrency.py +++ b/python/qpid/concurrency.py @@ -98,3 +98,9 @@ class Condition: self.lock._acquire_restore(st) self.waiting.remove(sw) self.waiters.append(sw) + + def gc(self): + assert self.lock._is_owned() + while self.waiters: + sw = self.waiters.pop(0) + sw.close() |