8162524: src/jdk.management/share/native/libmanagement_ext/Flag.c doesn't handle JNI exceptions
Add missed exception check Reviewed-by: dholmes, hb, dsamersoff
This commit is contained in:
parent
b7eda654ab
commit
496e48d0fb
@ -141,6 +141,13 @@ Java_com_sun_management_internal_Flag_getFlags
|
||||
// ignore unsupported type
|
||||
continue;
|
||||
}
|
||||
|
||||
if (valueObj == NULL) {
|
||||
free(globals);
|
||||
JNU_ThrowOutOfMemoryError(env, 0);
|
||||
return 0;
|
||||
}
|
||||
|
||||
switch (globals[i].origin) {
|
||||
case JMM_VMGLOBAL_ORIGIN_DEFAULT:
|
||||
origin = default_origin;
|
||||
|
Loading…
x
Reference in New Issue
Block a user