<html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><a href="https://bugs.openjdk.java.net/browse/JDK-8236661" class="">https://bugs.openjdk.java.net/browse/JDK-8236661</a><div class=""><br class=""></div><div class="">Don’t init ExtendedMapMode until modules have been initialized.</div><div class=""><br class=""></div><div class=""><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo; background-color: rgba(255, 255, 255, 0.811765);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">--- a/src/java.base/share/classes/sun/nio/ch/FileChannelImpl.java</span></div><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo; background-color: rgba(255, 255, 255, 0.811765);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">+++ b/src/java.base/share/classes/sun/nio/ch/FileChannelImpl.java</span></div></div><div class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo; background-color: rgba(255, 255, 255, 0.811765);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">@@ -49,6 +49,7 @@</span></div><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo; background-color: rgba(255, 255, 255, 0.811765);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""> import jdk.internal.access.SharedSecrets;</span></div><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo; background-color: rgba(255, 255, 255, 0.811765);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""> import jdk.internal.misc.ExtendedMapMode;</span></div><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo; background-color: rgba(255, 255, 255, 0.811765);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""> import jdk.internal.misc.Unsafe;</span></div><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo; background-color: rgba(255, 255, 255, 0.811765);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">+import jdk.internal.misc.VM;</span></div><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo; background-color: rgba(255, 255, 255, 0.811765);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""> import jdk.internal.ref.Cleaner;</span></div><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo; background-color: rgba(255, 255, 255, 0.811765);" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""> import jdk.internal.ref.CleanerFactory;</span></div><p style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo; background-color: rgba(255, 255, 255, 0.811765); min-height: 13px;" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""> </span><br class="webkit-block-placeholder"></p><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo; background-color: rgba(255, 255, 255, 0.811765);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">@@ -1116,8 +1117,11 @@</span></div><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo; background-color: rgba(255, 255, 255, 0.811765);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">     }</span></div><p style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo; background-color: rgba(255, 255, 255, 0.811765); min-height: 13px;" class=""><span style="font-variant-ligatures: no-common-ligatures" class=""> </span><br class="webkit-block-placeholder"></p><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo; background-color: rgba(255, 255, 255, 0.811765);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">     private boolean isSync(MapMode mode) {</span></div><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo; background-color: rgba(255, 255, 255, 0.811765);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">-        return mode == ExtendedMapMode.READ_ONLY_SYNC ||</span></div><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo; background-color: rgba(255, 255, 255, 0.811765);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">-                mode == ExtendedMapMode.READ_WRITE_SYNC;</span></div><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo; background-color: rgba(255, 255, 255, 0.811765);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">+        // Do not want to initialize ExtendedMapMode until</span></div><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo; background-color: rgba(255, 255, 255, 0.811765);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">+        // after the module system has been initialized</span></div><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo; background-color: rgba(255, 255, 255, 0.811765);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">+        return !VM.isModuleSystemInited() ? false :</span></div><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo; background-color: rgba(255, 255, 255, 0.811765);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">+            (mode == ExtendedMapMode.READ_ONLY_SYNC ||</span></div><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo; background-color: rgba(255, 255, 255, 0.811765);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">+                mode == ExtendedMapMode.READ_WRITE_SYNC);</span></div><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo; background-color: rgba(255, 255, 255, 0.811765);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">     }</span></div></span></div><div class=""><br class=""></div><div class="">Thanks,</div><div class=""><br class=""></div><div class="">Brian</div></body></html>