Skip to content

Commit d598609

Browse files
authored
test: avoid shell issues with Solaris 10 (#172)
avoiding export combined with assignment is also not valid POSIX sh
1 parent 5d523eb commit d598609

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

RunGrepTest

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -275,7 +275,7 @@ echo "---------------------------- Test 35 -----------------------------" >>test
275275
echo "RC=$?" >>testtrygrep
276276

277277
echo "---------------------------- Test 36 -----------------------------" >>testtrygrep
278-
(cd $srcdir; $valgrind $vjs $pcre2grep -L -r --include=grepinput[^C] --exclude 'grepinput$' --exclude=grepinput8 --exclude=grepinputM --exclude-dir='^\.' 'fox' ./testdata | sort) >>testtrygrep
278+
(cd $srcdir; $valgrind $vjs $pcre2grep -L -r --include='grepinput[^C]' --exclude 'grepinput$' --exclude=grepinput8 --exclude=grepinputM --exclude-dir='^\.' 'fox' ./testdata | sort) >>testtrygrep
279279
echo "RC=$?" >>testtrygrep
280280

281281
echo "---------------------------- Test 37 -----------------------------" >>testtrygrep
@@ -846,11 +846,7 @@ if [ $? -ne 0 ]; then
846846
echo "RC=2" >>testtrygrep
847847
else
848848

849-
# Bash has started giving a warning when LC_CTYPE is set to a bad value. In
850-
# order to remain compatible with older versions, the following code is a bit
851-
# contorted.
852-
853-
(cd $srcdir; unset LC_ALL; export LC_CTYPE=badlocale 2>/dev/null; $valgrind $vjs $pcre2grep abc /dev/null) >>testtrygrep 2>&1
849+
(cd $srcdir; unset LC_ALL; env LC_CTYPE=badlocale $valgrind $vjs $pcre2grep abc /dev/null) >>testtrygrep 2>&1
854850
echo "RC=$?" >>testtrygrep
855851
fi
856852

0 commit comments

Comments
 (0)