8167014: jdeps: Missing message: warn.skipped.entry

Reviewed-by: alanb, lancea
This commit is contained in:
Mandy Chung 2016-10-05 18:42:23 -07:00
parent 2db14bace5
commit b507e409eb
3 changed files with 11 additions and 6 deletions

View file

@ -438,7 +438,10 @@ public class ClassFileReader implements Closeable {
cf = reader.readClassFile(jf, nextEntry); cf = reader.readClassFile(jf, nextEntry);
return true; return true;
} catch (ClassFileError | IOException ex) { } catch (ClassFileError | IOException ex) {
skippedEntries.add(nextEntry.getName()); skippedEntries.add(String.format("%s: %s (%s)",
ex.getMessage(),
nextEntry.getName(),
jf.getName()));
} }
nextEntry = nextEntry(); nextEntry = nextEntry();
} }

View file

@ -605,11 +605,12 @@ class JdepsTask {
boolean ok = analyzer.run(options.compileTimeView, options.depth); boolean ok = analyzer.run(options.compileTimeView, options.depth);
// print skipped entries, if any // print skipped entries, if any
analyzer.archives() if (!options.nowarning) {
.forEach(archive -> archive.reader() analyzer.archives()
.skippedEntries().stream() .forEach(archive -> archive.reader()
.forEach(name -> warning("warn.skipped.entry", .skippedEntries().stream()
name, archive.getPathName()))); .forEach(name -> warning("warn.skipped.entry", name)));
}
if (options.findJDKInternals && !options.nowarning) { if (options.findJDKInternals && !options.nowarning) {
Map<String, String> jdkInternals = new TreeMap<>(); Map<String, String> jdkInternals = new TreeMap<>();

View file

@ -181,6 +181,7 @@ err.multirelease.option.notfound={0} is a multi-release jar file, but the --mult
err.multirelease.version.associated=class {0} already associated with version {1}, trying to add version {2} err.multirelease.version.associated=class {0} already associated with version {1}, trying to add version {2}
err.multirelease.jar.malformed=malformed multi-release jar, {0}, bad entry: {1} err.multirelease.jar.malformed=malformed multi-release jar, {0}, bad entry: {1}
warn.invalid.arg=Path does not exist: {0} warn.invalid.arg=Path does not exist: {0}
warn.skipped.entry={0}
warn.split.package=package {0} defined in {1} {2} warn.split.package=package {0} defined in {1} {2}
warn.replace.useJDKInternals=\ warn.replace.useJDKInternals=\
JDK internal APIs are unsupported and private to JDK implementation that are\n\ JDK internal APIs are unsupported and private to JDK implementation that are\n\