changeset 17370:9972141cb185

8162945: HotspotDiagnosticMXBean getFlags erroneously reports OutOfMemory Reviewed-by: egahlin, dcubed
author mgronlun
date Tue, 02 Aug 2016 18:36:47 +0200
parents 9672159305d7
children 9001adc78f9d d1e022a681cf
files src/jdk.management/share/native/libmanagement_ext/Flag.c
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/jdk.management/share/native/libmanagement_ext/Flag.c	Mon Aug 01 14:09:27 2016 +0000
+++ b/src/jdk.management/share/native/libmanagement_ext/Flag.c	Tue Aug 02 18:36:47 2016 +0200
@@ -142,7 +142,7 @@
             continue;
         }
 
-        if (valueObj == NULL) {
+        if (valueObj == NULL && globals[i].type != JMM_VMGLOBAL_TYPE_JSTRING) {
             free(globals);
             JNU_ThrowOutOfMemoryError(env, 0);
             return 0;