Related to the discussion in #32538. Our test_bitcoin
binary will output this warning when compiled with address
sanitzer:
0# clang version 20.1.3 (Fedora 20.1.3-1.fc43)
1cmake -B build -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ -DSANITIZERS=address
2cmake --build build
3./build/bin/test_bitcoin
4Running 655 test cases...
5==72451==Running thread 72090 was not suspended. False leaks are possible.
6
7*** No errors detected
However I couldn’t getctest
to output the same warning. i.e running:
0ctest --test-dir build -j20 --extra-verbose --debug | grep "False leaks"
does not produce the same warning.
If sanitizers are producing warnings, that output should be emitted, if not cause a test failure (if unsuppressed).
I’d also think that running ctest
vs running test_bitcoin
directly, should generally result in the same output, otherwise if sanitizers are producing warnings, or other relevant output, that is currently being “hidden” by ctest
.