Skip to content

Commit b7c33a1

Browse files
committed
Add missing utils_annotate_memory_inaccessible()
Signed-off-by: Lukasz Dorau <[email protected]>
1 parent a79338c commit b7c33a1

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/base_alloc/base_alloc_global.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -233,13 +233,15 @@ void umf_ba_global_free(void *ptr) {
233233
int ac_index = size_to_idx(total_size);
234234
if (ac_index >= NUM_ALLOCATION_CLASSES) {
235235
VALGRIND_DO_FREELIKE_BLOCK(ptr, 0);
236+
utils_annotate_memory_inaccessible(ptr, total_size);
236237
ba_os_free(ptr, total_size);
237238
return;
238239
}
239240

240241
if (!BASE_ALLOC.ac[ac_index]) {
241242
// if creating ac failed, memory must have been allocated by os
242243
VALGRIND_DO_FREELIKE_BLOCK(ptr, 0);
244+
utils_annotate_memory_inaccessible(ptr, total_size);
243245
ba_os_free(ptr, total_size);
244246
return;
245247
}

0 commit comments

Comments
 (0)