File:  [parser3project] / parser3 / tests / cat-windows.sh
Revision 1.3: download - view: text, annotated - select for diffs - revision graph
Sun Nov 24 16:11:41 2024 UTC (19 months, 2 weeks ago) by moko
Branches: MAIN
CVS tags: release_3_5_1, release_3_5_0, HEAD
tests for ^file::exec env and args tainting tests (related to bug #1239)

#!c:\cygwin\bin\sh.exe

if [ $1 = "halt" ]
then
	exit $2
fi

if [ $1 = "stdin" ]
then
	c:/cygwin/bin/cat.exe
	exit 0
fi

if [ $1 = "args" ]
then
	for arg in "$@"; do
		echo -n "\"$arg\" "
	done
	exit 0
fi

if [ $1 = "cgi" ]
then
	echo "content-type: $2
"
fi

if [ $1 = "env" ]
then
	eval "echo -n \"\$$2\""
fi

if [ -n "$5" ]
then
	echo "$5"
fi

c:/cygwin/bin/cat.exe -s $3

if [ -n "$4" ]
then
	exit $4
fi


E-mail: