1--- a/src/jdk.jlink/share/classes/jdk/tools/jlink/internal/plugins/LegalNoticeFilePlugin.java
2+++ b/src/jdk.jlink/share/classes/jdk/tools/jlink/internal/plugins/LegalNoticeFilePlugin.java
3@@ -112,18 +112,6 @@
4 .filter(e -> Arrays.equals(e.contentBytes(), entry.contentBytes()))
5 .findFirst();
6 if (!otarget.isPresent()) {
7- if (errorIfNotSameContent) {
8- // all legal notices of the same file name are expected
9- // to contain the same content
10- Optional<ResourcePoolEntry> ores =
11- entries.stream().filter(e -> e.linkedTarget() == null)
12- .findAny();
13-
14- if (ores.isPresent()) {
15- throw new PluginException(ores.get().path() + " " +
16- entry.path() + " contain different content");
17- }
18- }
19 entries.add(entry);
20 } else {
21 entries.add(ResourcePoolEntry.createSymLink(entry.path(),