8335283: Build failure due to 'no_sanitize' attribute directive ignored

Reviewed-by: shade, tschatzl, kbarrett, jwaters
This commit is contained in:
Matthias Baesken 2024-07-01 06:37:09 +00:00
parent d9bcf06145
commit 53242cdf9e

View File

@ -32,9 +32,11 @@
// following function or method.
// Useful if the function or method is known to do something special or even 'dangerous', for
// example causing desired signals/crashes.
#ifdef UNDEFINED_BEHAVIOR_SANITIZER
#if defined(__clang__) || defined(__GNUC__)
#define ATTRIBUTE_NO_UBSAN __attribute__((no_sanitize("undefined")))
#endif
#endif
#ifndef ATTRIBUTE_NO_UBSAN
#define ATTRIBUTE_NO_UBSAN