mirror of
https://github.com/RPCS3/llvm.git
synced 2024-11-25 04:39:51 +00:00
Avoid an infinite loop when TestRunner.sh is run outside of the test dir.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37201 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
47d2502072
commit
e01236a9bb
@ -13,11 +13,13 @@
|
||||
#
|
||||
TESTPATH=`pwd`
|
||||
SUBDIR=""
|
||||
while test `basename $TESTPATH` != "test" -a ! -z "$TESTPATH" ; do
|
||||
tmp=`basename $TESTPATH`
|
||||
SUBDIR="$tmp/$SUBDIR"
|
||||
TESTPATH=`dirname $TESTPATH`
|
||||
done
|
||||
if test `dirname $1` == "." ; then
|
||||
while test `basename $TESTPATH` != "test" -a ! -z "$TESTPATH" ; do
|
||||
tmp=`basename $TESTPATH`
|
||||
SUBDIR="$tmp/$SUBDIR"
|
||||
TESTPATH=`dirname $TESTPATH`
|
||||
done
|
||||
fi
|
||||
|
||||
for TESTFILE in "$@" ; do
|
||||
if test `dirname $TESTFILE` == . ; then
|
||||
|
Loading…
Reference in New Issue
Block a user