Skip to content

Commit 4760e50

Browse files
committed
[CI] Fix failing address sanitizer
1 parent feeb424 commit 4760e50

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/base_alloc/base_alloc_linux.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (C) 2024 Intel Corporation
2+
* Copyright (C) 2024-2025 Intel Corporation
33
*
44
* Under the Apache License v2.0 with LLVM Exceptions. See LICENSE.TXT.
55
* SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
@@ -19,8 +19,8 @@ static UTIL_ONCE_FLAG Page_size_is_initialized = UTIL_ONCE_FLAG_INIT;
1919
static size_t Page_size;
2020

2121
void *ba_os_alloc(size_t size) {
22-
void *ptr = mmap(NULL, size, PROT_READ | PROT_WRITE,
23-
MAP_PRIVATE | MAP_ANONYMOUS, -1, 0);
22+
void *ptr = utils_mmap(NULL, size, PROT_READ | PROT_WRITE,
23+
MAP_PRIVATE | MAP_ANONYMOUS, -1, 0);
2424
// this should be unnecessary but pairs of mmap/munmap do not reset
2525
// asan's user-poisoning flags, leading to invalid error reports
2626
// Bug 81619: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81619
@@ -29,7 +29,7 @@ void *ba_os_alloc(size_t size) {
2929
}
3030

3131
void ba_os_free(void *ptr, size_t size) {
32-
int ret = munmap(ptr, size);
32+
int ret = utils_munmap(ptr, size);
3333
assert(ret == 0);
3434
(void)ret; // unused
3535
}

0 commit comments

Comments
 (0)