changeset 41614:ac8cf125d8d5

merge: migrate to scmutil.backuppath() Differential Revision: https://phab.mercurial-scm.org/D5857
author Martin von Zweigbergk <martinvonz@google.com>
date Mon, 04 Feb 2019 21:19:05 -0800
parents a8ccd821b7d2
children 92bd3d86f2e0
files mercurial/merge.py
diffstat 1 files changed, 2 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/merge.py	Mon Feb 04 21:14:37 2019 -0800
+++ b/mercurial/merge.py	Mon Feb 04 21:19:05 2019 -0800
@@ -1506,9 +1506,8 @@
                             conflicting = p
                             break
                 if repo.wvfs.lexists(conflicting):
-                    absf = repo.wjoin(conflicting)
-                    orig = scmutil.origpath(ui, repo, absf)
-                    util.rename(absf, orig)
+                    orig = scmutil.backuppath(ui, repo, conflicting)
+                    util.rename(repo.wjoin(conflicting), orig)
             wctx[f].clearunknown()
             atomictemp = ui.configbool("experimental", "update.atomic-file")
             wctx[f].write(fctx(f).data(), flags, backgroundclose=True,