--- a/hotspot/agent/src/share/classes/sun/jvm/hotspot/tools/HeapSummary.java Mon Nov 02 12:34:27 2015 +0000
+++ b/hotspot/agent/src/share/classes/sun/jvm/hotspot/tools/HeapSummary.java Tue Nov 03 09:41:03 2015 +0100
@@ -268,8 +268,8 @@
VM vm = VM.getVM();
SystemDictionary sysDict = vm.getSystemDictionary();
InstanceKlass strKlass = sysDict.getStringKlass();
- // String has a field named 'value' of type 'char[]'.
- stringValueField = (OopField) strKlass.findField("value", "[C");
+ // String has a field named 'value' of type 'byte[]'.
+ stringValueField = (OopField) strKlass.findField("value", "[B");
}
private long stringSize(Instance instance) {