Skip to content

Commit

Permalink
configure.ac: fix memory sanitizer test
Browse files Browse the repository at this point in the history
We should test for `-fsanitize=memory` instead of `-fsanitize=thread`
when enabling memory sanitizer. While here, fix the error message.

Signed-off-by: Rafael Zalamena <rzalamena@opensourcerouting.org>
  • Loading branch information
rzalamena committed Oct 9, 2019
1 parent 6eb3b18 commit 65209e4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions configure.ac
Expand Up @@ -328,8 +328,8 @@ if test "$enable_thread_sanitizer" = "yes"; then
])
fi
if test "$enable_memory_sanitizer" = "yes"; then
AC_C_FLAG([-fsanitize=thread -fPIE -pie], [
AC_MSG_ERROR([$CC does not support Thread Sanitizer.])
AC_C_FLAG([-fsanitize=memory -fPIE -pie], [
AC_MSG_ERROR([$CC does not support Memory Sanitizer.])
], [
SAN_FLAGS="-fsanitize=memory -fPIE -pie"
])
Expand Down

0 comments on commit 65209e4

Please sign in to comment.