File tree 2 files changed +6
-0
lines changed
src/hotspot/share/jfr/recorder
2 files changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -103,6 +103,9 @@ bool JfrCheckpointManager::initialize() {
103
103
// preallocate buffer count to each of the epoch live lists
104
104
for (size_t i = 0 ; i < global_buffer_prealloc_count * 2 ; ++i) {
105
105
Buffer* const buffer = mspace_allocate (global_buffer_size, _global_mspace);
106
+ if (buffer == nullptr ) {
107
+ return false ;
108
+ }
106
109
_global_mspace->add_to_live_list (buffer, i % 2 == 0 );
107
110
}
108
111
assert (_global_mspace->free_list_is_empty (), " invariant" );
Original file line number Diff line number Diff line change @@ -85,6 +85,9 @@ bool JfrStringPool::initialize() {
85
85
// preallocate buffer count to each of the epoch live lists
86
86
for (size_t i = 0 ; i < string_pool_cache_count * 2 ; ++i) {
87
87
Buffer* const buffer = mspace_allocate (string_pool_buffer_size, _mspace);
88
+ if (buffer == nullptr ) {
89
+ return false ;
90
+ }
88
91
_mspace->add_to_live_list (buffer, i % 2 == 0 );
89
92
}
90
93
assert (_mspace->free_list_is_empty (), " invariant" );
You can’t perform that action at this time.
0 commit comments