
use this way to enable sanitizers make unittest check Sanitizer failed; it use _cflags to check
_cflags = sysconfig.get_config_var('CFLAGS') or ''
_config_args = sysconfig.get_config_var('CONFIG_ARGS') or ''
MEMORY_SANITIZER = (
'-fsanitize=memory' in _cflags or
'--with-memory-sanitizer' in _config_args
)
ADDRESS_SANITIZER = (
'-fsanitize=address' in _cflags
)
should replace with configure option
--with-address-sanitizer
enable AddressSanitizer memory error detector,
'asan' (default is no)
--with-memory-sanitizer enable MemorySanitizer allocation error detector,
'msan' (default is no)
--with-undefined-behavior-sanitizer
enable UndefinedBehaviorSanitizer undefined
behaviour detector, 'ubsan' (default is no)
Reactions are currently unavailable
use this way to enable sanitizers make unittest check Sanitizer failed; it use _cflags to check
_cflags = sysconfig.get_config_var('CFLAGS') or '' _config_args = sysconfig.get_config_var('CONFIG_ARGS') or '' MEMORY_SANITIZER = ( '-fsanitize=memory' in _cflags or '--with-memory-sanitizer' in _config_args ) ADDRESS_SANITIZER = ( '-fsanitize=address' in _cflags )should replace with configure option
--with-address-sanitizer enable AddressSanitizer memory error detector, 'asan' (default is no) --with-memory-sanitizer enable MemorySanitizer allocation error detector, 'msan' (default is no) --with-undefined-behavior-sanitizer enable UndefinedBehaviorSanitizer undefined behaviour detector, 'ubsan' (default is no)