svn commit: trunk/busybox/testsuite

vda at busybox.net vda at busybox.net
Fri May 2 09:39:09 UTC 2008


Author: vda
Date: 2008-05-02 02:39:09 -0700 (Fri, 02 May 2008)
New Revision: 21918

Log:
testing.sh: bashisms are eradicated.
By Cristian Ionescu-Idbohrn <cristian.ionescu-idbohrn AT axis.com>



Modified:
   trunk/busybox/testsuite/testing.sh


Changeset:
Modified: trunk/busybox/testsuite/testing.sh
===================================================================
--- trunk/busybox/testsuite/testing.sh	2008-05-02 09:19:29 UTC (rev 21917)
+++ trunk/busybox/testsuite/testing.sh	2008-05-02 09:39:09 UTC (rev 21918)
@@ -79,7 +79,7 @@
   cmp expected actual >/dev/null 2>/dev/null
   if [ $? -ne 0 ]
   then
-    FAILCOUNT=$[$FAILCOUNT+1]
+    FAILCOUNT=$(($FAILCOUNT + 1))
     echo "FAIL: $NAME"
     [ -n "$VERBOSE" ] && diff -u expected actual
   else
@@ -107,7 +107,8 @@
   shift
   for i in "$@"
   do
-    [ "${i:0:1}" == "/" ] || i=$(which $i)
+    #bashism: [ "${i:0:1}" == "/" ] || i=$(which $i)
+    i=$(which $i) # no-op for /bin/prog
     [ -f "$dest/$i" ] && continue
     if [ -e "$i" ]
     then




More information about the busybox-cvs mailing list