Hi,
the external call to `expr` is wasting resources.
And w/o the newline it looks nicer IMO:
--
Index: tools/randpkt-test.sh
===================================================================
--- tools/randpkt-test.sh (revision 44553)
+++ tools/randpkt-test.sh (working copy)
@@ -104,8 +104,8 @@
# Iterate over our capture files.
PASS=0
while [ $PASS -lt $MAX_PASSES -o $MAX_PASSES -lt 1 ] ; do
- PASS=`expr $PASS + 1`
- echo "Pass $PASS:"
+ ((PASS=$PASS + 1))
+ echo -en "\rPass $PASS:"
for PKT_TYPE in $PKT_TYPES ; do
if [ $PASS -gt $MAX_PASSES ] ; then break ; fi # We caught a signal
--
MfG/Sincerely
Toralf Förster
pgp finger print: 7B1A 07F4 EC82 0F90 D4C2 8936 872A E508 7DB6 9DA3