Skip to content

Commit f6e4da8

Browse files
committed
XMLBEANS-608 Fix memory leak
1 parent 2553772 commit f6e4da8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/main/java/org/apache/xmlbeans/impl/config/ChildSolverCollectionStrategy.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ private class FileVisitor extends SimpleFileVisitor<Path> {
105105
@Override
106106
public FileVisitResult visitFile(Path file, BasicFileAttributes attrs) throws IOException {
107107
if (javaMatcher.matches(file)) {
108-
if (roots.stream().noneMatch(file::startsWith)) {
108+
if (roots.stream().map(Path::toAbsolutePath).noneMatch(file.toAbsolutePath()::startsWith)) {
109109
getRoot(file).ifPresent(r -> {
110110
getSolver().add(new JavaParserTypeSolver(r, getParserConfiguration()));
111111
roots.add(r);

0 commit comments

Comments
 (0)