mercurial/transaction.py
changeset 6441 c9b8f2820bc0
parent 6065 53ed9b40cfc4
child 7334 618140c75d8d
--- a/mercurial/transaction.py	Mon Mar 31 23:14:25 2008 -0500
+++ b/mercurial/transaction.py	Mon Mar 31 23:02:25 2008 -0700
@@ -96,9 +96,13 @@
     files = {}
     for l in open(file).readlines():
         f, o = l.split('\0')
-        files[f] = o
+        files[f] = int(o)
     for f in files:
         o = files[f]
-        opener(f, "a").truncate(int(o))
+        if o:
+            opener(f, "a").truncate(int(o))
+        else:
+            fn = opener(f).name
+            os.unlink(fn)
     os.unlink(file)