File tree 2 files changed +10
-0
lines changed
src/hotspot/share/services
2 files changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -462,6 +462,11 @@ void DCmdFactory::send_notification_internal(TRAPS) {
462
462
if (notif) {
463
463
464
464
Klass* k = Management::com_sun_management_internal_DiagnosticCommandImpl_klass (CHECK);
465
+ if (k == nullptr ) {
466
+ fatal (" Should have the DiagnosticCommandImpl class" );
467
+ return ; // silence the compiler
468
+ }
469
+
465
470
InstanceKlass* dcmd_mbean_klass = InstanceKlass::cast (k);
466
471
467
472
JavaValue result (T_OBJECT);
Original file line number Diff line number Diff line change @@ -100,6 +100,11 @@ instanceOop MemoryManager::get_memory_manager_instance(TRAPS) {
100
100
signature = vmSymbols::createMemoryManager_signature ();
101
101
}
102
102
103
+ if (k == nullptr ) {
104
+ fatal (" Should have the ManagementFactoryHelper or GarbageCollectorExtImpl class" );
105
+ return nullptr ; // silence the compiler
106
+ }
107
+
103
108
InstanceKlass* ik = InstanceKlass::cast (k);
104
109
105
110
JavaCalls::call_static (&result,
You can’t perform that action at this time.
0 commit comments