summaryrefslogtreecommitdiffstats
path: root/src/vlibmemory/memory_api.c
diff options
context:
space:
mode:
authorBenoît Ganne <bganne@cisco.com>2019-04-15 15:28:21 +0200
committerDamjan Marion <dmarion@me.com>2019-11-27 10:50:28 +0000
commit9fb6d40eb3d4a2da8f45187de773498b784596e6 (patch)
treee785ebfbe73b847146debb2dae4a4304c51aa9cf /src/vlibmemory/memory_api.c
parent99fbf0574f099f09b7b46dcabe5bb50d78091dce (diff)
misc: add address sanitizer heap instrumentation
Introduce AddressSanitizer support: https://github.com/google/sanitizers/ This starts with heap instrumentation. vlib_buffer, bihash and stack instrumentation should follow. Type: feature Change-Id: I7f20e235b2f79db72efd0e756f22c75f717a9884 Signed-off-by: Benoît Ganne <bganne@cisco.com>
Diffstat (limited to 'src/vlibmemory/memory_api.c')
-rw-r--r--src/vlibmemory/memory_api.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/vlibmemory/memory_api.c b/src/vlibmemory/memory_api.c
index c9eebabfc50..42d1ee08a9f 100644
--- a/src/vlibmemory/memory_api.c
+++ b/src/vlibmemory/memory_api.c
@@ -210,6 +210,7 @@ vl_api_memclnt_create_t_handler (vl_api_memclnt_create_t * mp)
regp->clib_file_index = am->shmem_hdr->clib_file_index;
q = regp->vl_input_queue = (svm_queue_t *) (uword) mp->input_queue;
+ VL_MSG_API_SVM_QUEUE_UNPOISON (q);
regp->name = format (0, "%s", mp->name);
vec_add1 (regp->name, 0);
@@ -713,6 +714,7 @@ void_mem_api_handle_msg_i (api_main_t * am, vlib_main_t * vm,
uword mp;
if (!svm_queue_sub2 (q, (u8 *) & mp))
{
+ VL_MSG_API_UNPOISON ((void *) mp);
vl_msg_api_handler_with_vm_node (am, (void *) mp, vm, node);
return 0;
}