diff options
author | Damjan Marion <damarion@cisco.com> | 2022-04-05 12:40:31 +0200 |
---|---|---|
committer | Beno�t Ganne <bganne@cisco.com> | 2022-04-05 14:46:15 +0000 |
commit | 79934e855fc58aefde498cd0564796cdd6ccbc59 (patch) | |
tree | db3c5a33e1146915572160c33f2a0a8c9cbd18cd /src/vppinfra/vec.c | |
parent | 0c740a6d8a6c11b1af4ce704220c2c46628f0a89 (diff) |
vppinfra: refactor address sanitizer
Type: refactor
Change-Id: I5ca142ec1557d5b5c3806b43553ad9d3b5ea1112
Signed-off-by: Damjan Marion <damarion@cisco.com>
Diffstat (limited to 'src/vppinfra/vec.c')
-rw-r--r-- | src/vppinfra/vec.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/vppinfra/vec.c b/src/vppinfra/vec.c index 8bd0ec01f42..4dc8f18ce24 100644 --- a/src/vppinfra/vec.c +++ b/src/vppinfra/vec.c @@ -55,7 +55,7 @@ _vec_realloc (void *v, uword n_elts, uword elt_sz, uword hdr_sz, uword align, v = p + data_offset; } - CLIB_MEM_UNPOISON (p, alloc_size); + clib_mem_unpoison (p, alloc_size); clib_memset_u8 (p + old_data_size, 0, alloc_size - old_data_size); } else @@ -68,7 +68,7 @@ _vec_realloc (void *v, uword n_elts, uword elt_sz, uword hdr_sz, uword align, new_data_size = data_offset + n_data_bytes; p = clib_mem_heap_alloc_aligned (heap, new_data_size, align); alloc_size = clib_mem_size (p); - CLIB_MEM_UNPOISON (p, alloc_size); + clib_mem_unpoison (p, alloc_size); clib_memset_u8 (p, 0, alloc_size); v = p + data_offset; _vec_find (v)->hdr_size = data_offset / VEC_MIN_ALIGN; @@ -82,7 +82,7 @@ _vec_realloc (void *v, uword n_elts, uword elt_sz, uword hdr_sz, uword align, _vec_find (v)->default_heap = 1; } - CLIB_MEM_POISON (p + new_data_size, alloc_size - new_data_size); + clib_mem_poison (p + new_data_size, alloc_size - new_data_size); _vec_find (v)->len = n_elts; return v; } |