Show More
@@ -525,9 +525,11 b' class localrepository(repo.repository):' | |||||
525 | except IOError: |
|
525 | except IOError: | |
526 | ds = "" |
|
526 | ds = "" | |
527 | self.opener("journal.dirstate", "w").write(ds) |
|
527 | self.opener("journal.dirstate", "w").write(ds) | |
|
528 | self.opener("journal.branch", "w").write(self.dirstate.branch()) | |||
528 |
|
529 | |||
529 | renames = [(self.sjoin("journal"), self.sjoin("undo")), |
|
530 | renames = [(self.sjoin("journal"), self.sjoin("undo")), | |
530 |
(self.join("journal.dirstate"), self.join("undo.dirstate")) |
|
531 | (self.join("journal.dirstate"), self.join("undo.dirstate")), | |
|
532 | (self.join("journal.branch"), self.join("undo.branch"))] | |||
531 | tr = transaction.transaction(self.ui.warn, self.sopener, |
|
533 | tr = transaction.transaction(self.ui.warn, self.sopener, | |
532 | self.sjoin("journal"), |
|
534 | self.sjoin("journal"), | |
533 | aftertrans(renames)) |
|
535 | aftertrans(renames)) | |
@@ -557,6 +559,8 b' class localrepository(repo.repository):' | |||||
557 | self.ui.status(_("rolling back last transaction\n")) |
|
559 | self.ui.status(_("rolling back last transaction\n")) | |
558 | transaction.rollback(self.sopener, self.sjoin("undo")) |
|
560 | transaction.rollback(self.sopener, self.sjoin("undo")) | |
559 | util.rename(self.join("undo.dirstate"), self.join("dirstate")) |
|
561 | util.rename(self.join("undo.dirstate"), self.join("dirstate")) | |
|
562 | branch = self.opener("undo.branch").read() | |||
|
563 | self.dirstate.setbranch(branch) | |||
560 | self.invalidate() |
|
564 | self.invalidate() | |
561 | self.dirstate.invalidate() |
|
565 | self.dirstate.invalidate() | |
562 | else: |
|
566 | else: |
@@ -4,4 +4,4 b' adding changesets' | |||||
4 | transaction abort! |
|
4 | transaction abort! | |
5 | rollback completed |
|
5 | rollback completed | |
6 | killed! |
|
6 | killed! | |
7 | .hg/00changelog.i .hg/journal.dirstate .hg/requires .hg/store .hg/store/00changelog.i .hg/store/00changelog.i.a |
|
7 | .hg/00changelog.i .hg/journal.branch .hg/journal.dirstate .hg/requires .hg/store .hg/store/00changelog.i .hg/store/00changelog.i.a |
General Comments 0
You need to be logged in to leave comments.
Login now