From e2a648b41f3b80d00a4a0698a216ba3cfa2dc7f2 Mon Sep 17 00:00:00 2001 From: Martijn Dekker Date: Sun, 7 Jun 2020 23:35:17 +0200 Subject: [PATCH] tests/options.sh: fix child shell test by exporting variable src/cmd/ksh93/tests/options.sh: - Pipe hang bugfix test: The child shell has no idea how long to sleep for if we don't export the variable telling it so. (cherry picked from commit ede0960c4ec84f0f934b17072a892a4e40798e97) --- src/cmd/ksh93/tests/options.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/cmd/ksh93/tests/options.sh b/src/cmd/ksh93/tests/options.sh index b84c14744..6bbb31508 100755 --- a/src/cmd/ksh93/tests/options.sh +++ b/src/cmd/ksh93/tests/options.sh @@ -518,7 +518,8 @@ z=$($SHELL 2>&1 -uc 'print ${X23456789012345}') # pipe hang bug fixed 2011-03-15 float start=SECONDS toolong=3 -( $SHELL <<-EOF +( export toolong + $SHELL <<-EOF set -o pipefail (sleep $toolong;kill \$\$> /dev/null) & cat $SHELL | for ((i=0; i < 5; i++))