Fix classpath bug introduced with performance op.

This commit is contained in:
Fabian Becker 2014-10-21 09:40:45 +02:00
parent 10aaaa37c0
commit f5e71dbd36

View File

@ -230,7 +230,8 @@ public class ReflectPackage {
if (aDynCP.endsWith(".jar")) {
// Skip JARs that don't start with the EvA substring.
// This improves performance a lot when having a lot of JARs on the classpath
if (!aDynCP.substring(0, aDynCP.lastIndexOf(System.getProperty("file.separator"))).contains("EvA")) {
int index = aDynCP.lastIndexOf(System.getProperty("file.separator"));
if (index != -1 && !aDynCP.substring(0, index).contains("EvA")) {
continue;
}
getClassesFromJarFltr(set, aDynCP, pkg, includeSubs, reqSuperCls);