8175079: Lazy initialization of ImageReader breaks rmid
Reviewed-by: alanb
This commit is contained in:
parent
a141b69c1b
commit
cf871d92f9
@ -1945,9 +1945,6 @@ public final class System {
|
||||
// set security manager
|
||||
String cn = System.getProperty("java.security.manager");
|
||||
if (cn != null) {
|
||||
// ensure image reader for java.base is initialized before security manager
|
||||
Object.class.getResource("module-info.class");
|
||||
|
||||
if (cn.isEmpty() || "default".equals(cn)) {
|
||||
System.setSecurityManager(new SecurityManager());
|
||||
} else {
|
||||
|
@ -115,12 +115,7 @@ public final class ModuleBootstrap {
|
||||
long t0 = System.nanoTime();
|
||||
|
||||
// system modules (may be patched)
|
||||
ModuleFinder systemModules;
|
||||
if (SystemModules.MODULE_NAMES.length > 0) {
|
||||
systemModules = SystemModuleFinder.getInstance();
|
||||
} else {
|
||||
systemModules = ModuleFinder.ofSystem();
|
||||
}
|
||||
ModuleFinder systemModules = ModuleFinder.ofSystem();
|
||||
|
||||
PerfCounters.systemModulesTime.addElapsedTimeFrom(t0);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user