[Zodb-checkins] CVS: StandaloneZODB/bsddb3Storage/bsddb3Storage - CommitLog.py:1.8
Jeremy Hylton
jeremy@zope.com
Tue, 7 Aug 2001 18:14:17 -0400
Update of /cvs-repository/StandaloneZODB/bsddb3Storage/bsddb3Storage
In directory cvs.zope.org:/tmp/cvs-serv11059
Modified Files:
CommitLog.py
Log Message:
Make close() robust, which in turn silences complaints about
exceptions in __del__ that occur when the test suite is run.
=== StandaloneZODB/bsddb3Storage/bsddb3Storage/CommitLog.py 1.7 => 1.8 ===
if self._fp:
self._fp.close()
- if unlink or self._unlink:
+ if (unlink or self._unlink) and os.path.exists(self._fp.name):
os.unlink(self._fp.name)
self._fp = None