[Zodb-checkins] CVS: ZODB3/ZODB - BaseStorage.py:1.24.2.2.4.1
Jeremy Hylton
jeremy@zope.com
Tue, 17 Dec 2002 11:59:32 -0500
Update of /cvs-repository/ZODB3/ZODB
In directory cvs.zope.org:/tmp/cvs-serv18304
Modified Files:
Tag: ZODB3-fast-restart-branch
BaseStorage.py
Log Message:
Explicitly close the iterator in copyTransactionsFrom().
=== ZODB3/ZODB/BaseStorage.py 1.24.2.2 => 1.24.2.2.4.1 ===
--- ZODB3/ZODB/BaseStorage.py:1.24.2.2 Tue Nov 12 15:18:09 2002
+++ ZODB3/ZODB/BaseStorage.py Tue Dec 17 11:59:32 2002
@@ -265,8 +265,8 @@
restoring = 1
else:
restoring = 0
- for transaction in other.iterator():
-
+ fiter = other.iterator()
+ for transaction in fiter:
tid=transaction.tid
if _ts is None:
_ts=TimeStamp(tid)
@@ -299,6 +299,8 @@
self.tpc_vote(transaction)
self.tpc_finish(transaction)
+
+ fiter.close()
class TransactionRecord:
"""Abstract base class for iterator protocol"""