aboutsummaryrefslogtreecommitdiffstats
path: root/tools/runlex.sh
diff options
context:
space:
mode:
authorGuy Harris <guy@alum.mit.edu>2007-08-04 03:11:06 +0000
committerGuy Harris <guy@alum.mit.edu>2007-08-04 03:11:06 +0000
commitc2d8a39d95aa38a82a918eef4c00f85fd3814668 (patch)
tree273d2d8c9f72765b52a67d0d692ad9d0f813df41 /tools/runlex.sh
parent517d6d57e4dbf1953ec65b99ad276d59ac0717b7 (diff)
Sigh, crufty old shells. The Solaris test(1) manual says that
1) "-e" isn't supported by good old /bin/sh, so we use "-r" instead; 2) "The algorithm for determining the precedence of the operators and the return value that will be generated is based on the number of arguments presented to test", so we explicitly parenthesize. svn path=/trunk/; revision=22448
Diffstat (limited to 'tools/runlex.sh')
-rwxr-xr-xtools/runlex.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/runlex.sh b/tools/runlex.sh
index c70c46eeed..e08dae0860 100755
--- a/tools/runlex.sh
+++ b/tools/runlex.sh
@@ -107,7 +107,7 @@ fi
# Is the outfile where we think it is?
#
outfile_base=`basename "$outfile"`
-if [ "$outfile_base" != "$outfile" -a ! -e "$outfile" -a -e "$outfile_base" ]
+if [ "$outfile_base" != "$outfile" -a \( ! -r "$outfile" \) -a -r "$outfile_base" ]
then
#
# No, it's not, but it is in the current directory. Put it