From: Jim Meyering Date: Thu, 20 Aug 2009 16:27:07 +0000 (+0200) Subject: tests: skip the stdbuf tests when the abs build directory name is bogus X-Git-Tag: v7.5~1 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=7f242fadfa216eac6ebb20721943b6e4e90300c7;p=thirdparty%2Fcoreutils.git tests: skip the stdbuf tests when the abs build directory name is bogus * tests/misc/stdbuf: Avoid spurious failure when the directory name from which we'd set LD_PRELOAD contains unsafe characters. --- diff --git a/tests/misc/stdbuf b/tests/misc/stdbuf index a9aed43d59..337504028f 100755 --- a/tests/misc/stdbuf +++ b/tests/misc/stdbuf @@ -30,6 +30,14 @@ case " $built_programs " in *) skip_test_ 'stdbuf not built';; esac +# stdbuf fails when the absolute top build dir name contains e.g., space, TAB, NL +lf=' +' +case $abs_top_builddir in + *[\\\"\#\$\&\'\`$lf\ \ ]*) + skip_test_ "unsafe absolute build directory name: $abs_top_builddir";; +esac + # Use a fifo rather than a pipe in the tests below # so that the producer (uniq) will wait until the # consumer (dd) opens the fifo therefore increasing