[prev in list] [next in list] [prev in thread] [next in thread]
List: openjdk-serviceability-dev
Subject: RFR(S): 7178846: IterateThroughHeap: heap_iteration_callback passes a negative size for big array
From: markus.gronlund () oracle ! com (=?iso-8859-1?B?TWFya3VzIEdy9m5sdW5k?=)
Date: 2012-06-25 12:31:07
Message-ID: d46baead-d94c-4377-90ff-9b8953b1abd3 () default
[Download RAW message or body]
Change looks good Staffan.
?
Thanks for fixing this
/Markus
?
From: Staffan Larsen [mailto:staffan at larsen.se]
Sent: den 25 juni 2012 10:06
To: serviceability-dev serviceability-dev at openjdk.java.net
Subject: RFR(S): 7178846: IterateThroughHeap: heap_iteration_callback passes a \
negative size for big array
?
Please review the following fix.
?
Bug:?http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=7178846
Webrev:?http://cr.openjdk.java.net/~sla/7178846/webrev.01/
?
Class CallbackWrapper in jvmtiTagMap.cpp has a missing cast which leads to an integer \
overflow.
?
The code in question is
? ? _obj_size = _o->size() * wordSize;
?
_obj_size is a jlong
_o->size() is an int
wordSize is an int
?
Changing to:
? ? _obj_size = (jlong)_o->size() * wordSize;
?
fixes the overflow.
?
Thanks,
/Staffan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.openjdk.java.net/pipermail/serviceability-dev/attachments/20120625/350f5de5/attachment.html \
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic