--- a/hotspot/src/share/vm/classfile/systemDictionary.cpp Tue Oct 18 16:09:34 2016 +0000
+++ b/hotspot/src/share/vm/classfile/systemDictionary.cpp Mon Oct 10 20:50:33 2016 -0400
@@ -1234,7 +1234,7 @@
SharedClassPathEntry* ent =
(SharedClassPathEntry*)FileMapInfo::shared_classpath(path_index);
if (!Universe::is_module_initialized()) {
- assert(ent->is_jrt(),
+ assert(ent != NULL && ent->is_jrt(),
"Loading non-bootstrap classes before the module system is initialized");
assert(class_loader.is_null(), "sanity");
return true;
@@ -1257,6 +1257,7 @@
}
if (class_loader.is_null()) {
+ assert(ent != NULL, "Shared class for NULL classloader must have valid SharedClassPathEntry");
// The NULL classloader can load archived class originated from the
// "modules" jimage and the -Xbootclasspath/a. For class from the
// "modules" jimage, the PackageEntry/ModuleEntry must be defined