hotspot/src/share/vm/classfile/systemDictionary.cpp
changeset 41739 4a4b9f6a4306
parent 41182 dbd59c1da636
child 42074 c069e5e285cb
--- 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