diff --git a/mercurial/util.py b/mercurial/util.py --- a/mercurial/util.py +++ b/mercurial/util.py @@ -509,8 +509,7 @@ def _matcher(canonroot, cwd, names, inc, excmatch = matchfn(exckinds, '(?:/|$)') return (roots, - lambda fn: (incmatch(fn) and not excmatch(fn) and - (fn.endswith('/') or patmatch(fn))), + lambda fn: (incmatch(fn) and not excmatch(fn) and patmatch(fn)), (inc or exc or anypats) and True) def system(cmd, environ={}, cwd=None, onerr=None, errprefix=None):