hgext/rebase.py
branchstable
changeset 15464 3411a83e232a
parent 15289 9cec4b24615b
child 15469 ad336e093a59
--- a/hgext/rebase.py	Tue Nov 08 21:31:39 2011 +0100
+++ b/hgext/rebase.py	Sun Nov 06 23:35:33 2011 +0100
@@ -479,7 +479,10 @@
     f.write('%d\n' % int(keepbranches))
     for d, v in state.iteritems():
         oldrev = repo[d].hex()
-        newrev = repo[v].hex()
+        if v != nullmerge:
+            newrev = repo[v].hex()
+        else:
+            newrev = v
         f.write("%s:%s\n" % (oldrev, newrev))
     f.close()
     repo.ui.debug('rebase status stored\n')
@@ -512,7 +515,10 @@
                 keepbranches = bool(int(l))
             else:
                 oldrev, newrev = l.split(':')
-                state[repo[oldrev].rev()] = repo[newrev].rev()
+                if newrev != str(nullmerge):
+                    state[repo[oldrev].rev()] = repo[newrev].rev()
+                else:
+                    state[repo[oldrev].rev()] = int(newrev)
         skipped = set()
         # recompute the set of skipped revs
         if not collapse: