mirror of
https://github.com/openjdk/jdk.git
synced 2026-03-25 15:20:11 +00:00
8292972: Initialize fields if CodeBlobIterator shortcuts without heaps
Reviewed-by: kvn, chagedorn
This commit is contained in:
parent
a476ec5c81
commit
512fee1d1e
@ -380,6 +380,10 @@ template <class T, class Filter, bool is_relaxed> class CodeBlobIterator : publi
|
||||
: _only_not_unloading(filter == only_not_unloading)
|
||||
{
|
||||
if (Filter::heaps() == NULL) {
|
||||
// The iterator is supposed to shortcut since we have
|
||||
// _heap == _end, but make sure we do not have garbage
|
||||
// in other fields as well.
|
||||
_code_blob = nullptr;
|
||||
return;
|
||||
}
|
||||
_heap = Filter::heaps()->begin();
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user