Commit f03a02bd authored by Jeremy Hylton's avatar Jeremy Hylton

Make close() robust, which in turn silences complaints about

exceptions in __del__ that occur when the test suite is run.
parent 64129aa4
......@@ -276,7 +276,7 @@ class CommitLog:
"""
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
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment