--- a/mercurial/dirstate.py Tue Oct 07 11:42:37 2014 -0700
+++ b/mercurial/dirstate.py Fri Oct 10 13:05:50 2014 -0500
@@ -266,12 +266,17 @@
self._pl = p1, p2
copies = {}
if oldp2 != nullid and p2 == nullid:
- # Discard 'm' markers when moving away from a merge state
for f, s in self._map.iteritems():
+ # Discard 'm' markers when moving away from a merge state
if s[0] == 'm':
if f in self._copymap:
copies[f] = self._copymap[f]
self.normallookup(f)
+ # Also fix up otherparent markers
+ elif s[0] == 'n' and s[2] == -2:
+ if f in self._copymap:
+ copies[f] = self._copymap[f]
+ self.add(f)
return copies
def setbranch(self, branch):
--- a/tests/test-histedit-no-change.t Tue Oct 07 11:42:37 2014 -0700
+++ b/tests/test-histedit-no-change.t Fri Oct 10 13:05:50 2014 -0500
@@ -181,7 +181,7 @@
parent: 0:cb9a9f314b8b
a
branch: default
- commit: 1 modified, 1 unknown (new branch head)
+ commit: 1 added, 1 unknown (new branch head)
update: 6 new changesets (update)
hist: 2 remaining (histedit --continue)
@@ -190,7 +190,7 @@
modified files should survive the abort when we've moved away already
$ hg st
- M e
+ A e
? edit.sh
$ graphlog "log after abort"
--- a/tests/test-rebase-collapse.t Tue Oct 07 11:42:37 2014 -0700
+++ b/tests/test-rebase-collapse.t Fri Oct 10 13:05:50 2014 -0500
@@ -71,9 +71,9 @@
HG: --
HG: user: Nicolas Dumazet <nicdumz.commits@gmail.com>
HG: branch 'default'
- HG: changed B
- HG: changed C
- HG: changed D
+ HG: added B
+ HG: added C
+ HG: added D
====
saved backup bundle to $TESTTMP/a1/.hg/strip-backup/*-backup.hg (glob)
--- a/tests/test-rebase-scenario-global.t Tue Oct 07 11:42:37 2014 -0700
+++ b/tests/test-rebase-scenario-global.t Fri Oct 10 13:05:50 2014 -0500
@@ -59,7 +59,7 @@
HG: --
HG: user: Nicolas Dumazet <nicdumz.commits@gmail.com>
HG: branch 'default'
- HG: changed D
+ HG: added D
saved backup bundle to $TESTTMP/a1/.hg/strip-backup/*-backup.hg (glob)
$ hg tglog