Remove dependency of ltt-arm/disarmall on bash idioms
authorMathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
Wed, 18 Nov 2009 16:17:30 +0000 (11:17 -0500)
committerMathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
Wed, 18 Nov 2009 16:17:30 +0000 (11:17 -0500)
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
lttctl/ltt-armall.sh
lttctl/ltt-disarmall.sh

index 9eda365490dc5052b6cfc65a766dd0f4ff7e55b1..307f0b13f6084d1112105beea794c51bab874ed7 100755 (executable)
@@ -62,9 +62,9 @@ if [ ! ${NETWORK} ]; then
        TESTS="${TESTS} -path '*/net/*_extended' -prune -o"
 fi
 
-while read -r -d $'\0' marker; do
+(eval "find '${MARKERSROOT}' ${TESTS} -name metadata -prune -o -name enable -print0") | while read -r -d $'\0' marker; do
        if [ ! ${QUIET} ]; then
                echo "Connecting ${marker%/enable}"
        fi
        echo 1 > ${marker}
-done < <(eval "find '${MARKERSROOT}' ${TESTS} -name metadata -prune -o -name enable -print0")
+done
index aa1a0d7736160e5676435d94b63df662b37421da..64e65a426a7280fb74e2f0bc3433a5d66294a4c9 100755 (executable)
@@ -48,7 +48,7 @@ while getopts "qh" options; do
 done
 shift $((${OPTIND} - 1))
 
-while read -r -d $'\0' marker; do
+(eval "find '${MARKERSROOT}' -name metadata -prune -o -name enable -print0") | while read -r -d $'\0' marker; do
        grep "^1$" "${marker}" -q
        if [ $? -ne 0 ]; then
                continue
@@ -57,4 +57,4 @@ while read -r -d $'\0' marker; do
                echo "Disconnecting ${marker%/enable}"
        fi
        echo 0 > ${marker}
-done < <(eval "find '${MARKERSROOT}' -name metadata -prune -o -name enable -print0")
+done
This page took 0.024384 seconds and 4 git commands to generate.