changeset 27025:ec37257341a9

resolve: fix incorrect merge The merge from stable into default was semantically incomplete -- a couple of changes in preceding code had to be rewritten here. This code only triggers for change/delete conflicts, so we can't test it yet. We will soon be able to do it, though.
author Siddharth Agarwal <sid0@fb.com>
date Wed, 18 Nov 2015 23:43:18 -0800
parents ceef5fb14872
children c93b44b79359
files mercurial/commands.py
diffstat 1 files changed, 5 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/commands.py	Wed Nov 18 20:55:32 2015 +0100
+++ b/mercurial/commands.py	Wed Nov 18 23:43:18 2015 -0800
@@ -5704,7 +5704,11 @@
 
             # replace filemerge's .orig file with our resolve file
             a = repo.wjoin(f)
-            util.rename(a + ".resolve", a + ".orig")
+            try:
+                util.rename(a + ".resolve", cmdutil.origpath(ui, repo, a))
+            except OSError as inst:
+                if inst.errno != errno.ENOENT:
+                    raise
 
         ms.commit()