mirror of
https://git.savannah.gnu.org/git/coreutils.git
synced 2026-11-17 18:02:09 +03:00
tests: avoid false test failure when using address sanitizer
* tests/misc/warning-errors.sh: Skip commands which have been built with sanitizers, since standard error will not be closed and checked for errors. Reported by Bruno Haible.
This commit is contained in:
1 parent
74d7018012
commit
8177a9ac16
1 file changed
+3
@@ -64,6 +64,9 @@ expected_failure_status_env=0 # env's exec resets default exit handlers
|
||||
|
||||
while read writer; do
|
||||
cmd=$(printf '%s\n' "$writer" | cut -d ' ' -f1) || framework_failure_
|
||||
# We don't close standard error with sanitizers, which may need to print.
|
||||
# Therefore, these programs may succeed when they otherwise wouldn't.
|
||||
sanitizer_build_ $cmd && continue
|
||||
eval "expected=\$expected_failure_status_$cmd"
|
||||
test x$expected = x && expected=1
|
||||
returns_ $expected \
|
||||
|
||||
Reference in new issue
Block a user