From 396e885886b2665850c3b10e4cd029cffffce1b7 Mon Sep 17 00:00:00 2001 From: Hennadii Stepanov <32963518+hebasto@users.noreply.github.com> Date: Tue, 28 May 2024 09:44:47 +0100 Subject: [PATCH] autotools: Align MSan checking code with CMake's implementation --- build-aux/m4/bitcoin_secp.m4 | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/build-aux/m4/bitcoin_secp.m4 b/build-aux/m4/bitcoin_secp.m4 index fee2d7b..048267f 100644 --- a/build-aux/m4/bitcoin_secp.m4 +++ b/build-aux/m4/bitcoin_secp.m4 @@ -50,10 +50,14 @@ AC_MSG_CHECKING(whether MemorySanitizer is enabled) AC_COMPILE_IFELSE([AC_LANG_SOURCE([[ #if defined(__has_feature) # if __has_feature(memory_sanitizer) - # error "MemorySanitizer is enabled." + /* MemorySanitizer is enabled. */ + # elif + # error "MemorySanitizer is disabled." # endif + #else + # error "__has_feature is not defined." #endif - ]])], [msan_enabled=no], [msan_enabled=yes]) + ]])], [msan_enabled=yes], [msan_enabled=no]) AC_MSG_RESULT([$msan_enabled]) ])