--- a/mercurial/cmdutil.py Thu May 18 18:00:38 2017 -0400
+++ b/mercurial/cmdutil.py Thu May 18 18:00:52 2017 -0400
@@ -609,7 +609,7 @@
else:
badstates = '?r'
m = scmutil.match(repo[None], [pat], opts, globbed=True)
- for abs in repo.walk(m):
+ for abs in repo[None].walk(m):
state = repo.dirstate[abs]
rel = m.rel(abs)
exact = m.exact(abs)
@@ -2941,7 +2941,8 @@
targetsubs = sorted(s for s in wctx.substate if m(s))
if not m.always():
- for abs in repo.walk(matchmod.badmatch(m, lambda x, y: False)):
+ matcher = matchmod.badmatch(m, lambda x, y: False)
+ for abs in repo[None].walk(matcher):
names[abs] = m.rel(abs), m.exact(abs)
# walk target manifest to fill `names`