Browse Source

Merge "Revert "Stop PathFilter after walking all matching paths""

stable-2.3
Robin Rosenberg 12 years ago committed by Gerrit Code Review @ Eclipse.org
parent
commit
c8c258169f
  1. 6
      org.eclipse.jgit/src/org/eclipse/jgit/treewalk/filter/PathFilter.java

6
org.eclipse.jgit/src/org/eclipse/jgit/treewalk/filter/PathFilter.java

@ -44,7 +44,6 @@
package org.eclipse.jgit.treewalk.filter;
import org.eclipse.jgit.errors.StopWalkException;
import org.eclipse.jgit.internal.JGitText;
import org.eclipse.jgit.lib.Constants;
import org.eclipse.jgit.treewalk.TreeWalk;
@ -98,10 +97,7 @@ public class PathFilter extends TreeFilter {
@Override
public boolean include(final TreeWalk walker) {
int cmp = walker.isPathPrefix(pathRaw, pathRaw.length);
if (cmp > 0)
throw StopWalkException.INSTANCE;
return cmp == 0;
return walker.isPathPrefix(pathRaw, pathRaw.length) == 0;
}
@Override

Loading…
Cancel
Save