D627: filemerge: flush if using deferred writes when running a merge tool

phillco (Phil Cohen) phabricator at mercurial-scm.org
Sun Sep 10 23:55:14 EDT 2017


phillco updated this revision to Diff 1700.

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D627?vs=1671&id=1700

REVISION DETAIL
  https://phab.mercurial-scm.org/D627

AFFECTED FILES
  mercurial/filemerge.py

CHANGE DETAILS

diff --git a/mercurial/filemerge.py b/mercurial/filemerge.py
--- a/mercurial/filemerge.py
+++ b/mercurial/filemerge.py
@@ -666,6 +666,11 @@
         onfailure = _("merging %s failed!\n")
         precheck = None
 
+        # If using deferred writes, must flush any deferred contents if running
+        # an external merge tool since it has arbitrary access to the working
+        # copy.
+        wctx.flushall()
+
     toolconf = tool, toolpath, binary, symlink
 
     if mergetype == nomerge:



To: phillco, #hg-reviewers
Cc: quark, martinvonz, mercurial-devel


More information about the Mercurial-devel mailing list