transaction: fix file descriptor leak for journal.backupfiles
The journal.backupfiles descriptor wasn't being closed. This resulted in
hgsubversion test runs having a bagillion descriptors open, which crashed on
platforms with low open file limits (like OSX).
--- a/mercurial/transaction.py Fri Apr 25 18:00:07 2014 -0700
+++ b/mercurial/transaction.py Wed Apr 30 15:36:38 2014 -0700
@@ -220,6 +220,7 @@
if self.count != 0:
return
self.file.close()
+ self.backupsfile.close()
self.entries = []
if self.after:
self.after()
@@ -243,6 +244,7 @@
self.count = 0
self.usages = 0
self.file.close()
+ self.backupsfile.close()
if self.onabort is not None:
self.onabort()