Ignore:
Timestamp:
Jun 26, 2009, 10:43:23 AM (15 years ago)
Author:
rosiere
Message:

1) Correct bug in link two signal
2) Fix error detected with valgrind
3) modif distexe script

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/IPs/systemC/processor/Morpheo/Script/distexe.sh

    r126 r128  
    55#-----------------------------------------------------------
    66
    7 VERSION="1.0"
     7declare    VERSION="1.0"
     8declare -i SLEEP=3
    89
    910# Need : test, echo, cd, dirname, basename, ssh, ps aux
     
    106107   
    107108    header;
    108     echo "  * {"$(my_date)"} <${HOSTNAME}> file : ${FILE_CMD}";
    109     echo "  * {"$(my_date)"} <${HOSTNAME}> path : ${PATH_EXE}";
     109
     110    echo "  * {"$(my_date)"} <${HOSTNAME}> file  : ${FILE_CMD}";
     111    echo "  * {"$(my_date)"} <${HOSTNAME}> path  : ${PATH_EXE}";
     112    echo "  * {"$(my_date)"} <${HOSTNAME}> sleep : ${SLEEP}";
    110113
    111114    local hosts="${DISTEXE_HOSTS}";
     
    133136        local -i res=1
    134137
    135         while test ${res} -ne 0; do
     138        while true; do
    136139            res=$(ps aux | grep -c "${commands[${cpt}]}");
     140
     141            if test ${res} -eq 0; then
     142                break;
     143            fi;
     144
     145            # wait (to not have 100% cpu)
     146            sleep ${SLEEP};
    137147        done
    138148
Note: See TracChangeset for help on using the changeset viewer.