changeset 3521:588f559105c1

7178846: IterateThroughHeap: heap_iteration_callback passes a negative size Summary: Missing cast caused integer overflow Reviewed-by: rbackman, dholmes
author sla
date Mon, 25 Jun 2012 14:34:35 +0200
parents d8a240abb23a
children 36b2d4cfcf03
files src/share/vm/prims/jvmtiTagMap.cpp
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/share/vm/prims/jvmtiTagMap.cpp	Fri Jun 22 15:39:16 2012 -0700
+++ b/src/share/vm/prims/jvmtiTagMap.cpp	Mon Jun 25 14:34:35 2012 +0200
@@ -585,7 +585,7 @@
     _o = klassOop_if_java_lang_Class(o);
 
     // object size
-    _obj_size = _o->size() * wordSize;
+    _obj_size = (jlong)_o->size() * wordSize;
 
     // record the context
     _tag_map = tag_map;