Skip to content

Commit

Permalink
fix comment and remove unneccesary logging of common scenario
Browse files Browse the repository at this point in the history
  • Loading branch information
hcoles committed Aug 30, 2024
1 parent 4c86cb4 commit 856e9f7
Showing 1 changed file with 2 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -377,17 +377,15 @@ private CoverageGenerator coverage() {
return this.strategies.coverage();
}

// For reasons not yet understood classes from rt.jar are not resolved for some
// projects during static analysis phase. For now fall back to the classloader when
// a class not provided by project classpath
// Since java 9 rt.jar is no longer on the classpath so jdk classes will not resolve from
// the filesystem and must be pulled out via the classloader
private ClassByteArraySource fallbackToClassLoader(final ClassByteArraySource bas) {
final ClassByteArraySource clSource = ClassloaderByteArraySource.fromContext();
return clazz -> {
final Optional<byte[]> maybeBytes = bas.getBytes(clazz);
if (maybeBytes.isPresent()) {
return maybeBytes;
}
LOG.log(Level.FINE, "Could not find " + clazz + " on classpath for analysis. Falling back to classloader");
return clSource.getBytes(clazz);
};
}
Expand Down

0 comments on commit 856e9f7

Please sign in to comment.