Build: Enable std::vector ASAN annotation in libstdc++
By defining _GLIBCXX_SANITIZE_VECTOR when ASAN is enabled `std::vector` operations will be annotated so ASAN can detect invalid accesses. See https://gcc.gnu.org/onlinedocs/libstdc++/manual/using_macros.html
This commit is contained in:
parent
09b0353592
commit
e8adf5d331
|
@ -20,6 +20,7 @@ endif()
|
|||
if(ASAN)
|
||||
target_compile_options(zm-compile-option-interface
|
||||
INTERFACE
|
||||
-D_GLIBCXX_SANITIZE_VECTOR=1
|
||||
-fno-omit-frame-pointer
|
||||
-fsanitize=address
|
||||
-fsanitize-recover=address
|
||||
|
|
Loading…
Reference in New Issue