X-Git-Url: https://git.teslayout.com/public/public/public/?p=anna.git;a=blobdiff_plain;f=example%2Fdiameter%2Flauncher%2Fresources%2Fscripts%2Foperation_signal.sh;h=87e4ce5a586b9bac241d032ce36bb11b9cec4090;hp=eb0eb8e1d32447e44f301618dadf7ffff067bd3a;hb=ea1b80f8fd0c1b806460f98f4e4cf433698857d9;hpb=d33231f088c5ff6a137d63285c91536ac3598bf4 diff --git a/example/diameter/launcher/resources/scripts/operation_signal.sh b/example/diameter/launcher/resources/scripts/operation_signal.sh index eb0eb8e..87e4ce5 100755 --- a/example/diameter/launcher/resources/scripts/operation_signal.sh +++ b/example/diameter/launcher/resources/scripts/operation_signal.sh @@ -21,7 +21,7 @@ usage() { echo " -h|--help: this usage help." echo " -t|--timeout : timeout for operation in seconds." echo " Defaults to $TIMEOUT__dflt seconds if not provided." - echo " -f|--file : file with one operation per line." + echo " -f|--file : file with one operation per line (comments # allowed)." echo " -p|--ping: Check the target process id." echo " Returns 1 (dead) or 0 (alive)." echo " operation: quoted operation string. Will be ignored if file" @@ -116,17 +116,17 @@ check_pid $PID kill -s SIGUSR2 $PID # Detect EOF and print all except that last line: -count=$((10*timeout)) +count=$((10*timeout)) expired=yes -while [ $count -gt 0 ] -do - sleep 0.1 - count=$((count-1)) +while [ $count -gt 0 ] +do + sleep 0.1 + count=$((count-1)) if tail -1 sigusr2.out | grep "^EOF" >/dev/null; then expired= break; fi -done +done if [ -z "$expired" ] then