diff mercurial/commands.py @ 41281:183df3df6031

resolve: fix mark-check when a file was deleted on one side (issue6020) wvfs.open raises an error if one of the files does not exist. Ignoring the error if it's ENOENT is done in several other places in this code, so I'm in good company :) Differential Revision: https://phab.mercurial-scm.org/D5243
author Kyle Lippincott <spectral@google.com>
date Wed, 07 Nov 2018 15:45:09 -0800
parents 08dd462ea782
children 876494fd967d 8427fea04017
line wrap: on
line diff
--- a/mercurial/commands.py	Fri Jan 04 16:04:48 2019 +0100
+++ b/mercurial/commands.py	Wed Nov 07 15:45:09 2018 -0800
@@ -4935,8 +4935,7 @@
 
             if mark:
                 if markcheck:
-                    with repo.wvfs(f) as fobj:
-                        fdata = fobj.read()
+                    fdata = repo.wvfs.tryread(f)
                     if filemerge.hasconflictmarkers(fdata) and \
                         ms[f] != mergemod.MERGE_RECORD_RESOLVED:
                         hasconflictmarkers.append(f)