about summary refs log tree commit diff
path: root/localedata/tst-fmon.sh
diff options
context:
space:
mode:
Diffstat (limited to 'localedata/tst-fmon.sh')
-rwxr-xr-xlocaledata/tst-fmon.sh13
1 files changed, 7 insertions, 6 deletions
diff --git a/localedata/tst-fmon.sh b/localedata/tst-fmon.sh
index e58db1d344..c8b6d69949 100755
--- a/localedata/tst-fmon.sh
+++ b/localedata/tst-fmon.sh
@@ -39,25 +39,26 @@ for cns in `cd ./tst-fmon-locales && ls tstfmon_*`; do
 done
 
 # Run the tests.
+errcode=0
 # There's a TAB for IFS
 while IFS="	" read locale format value expect; do
     case "$locale" in '#'*) continue ;; esac
     if [ -n "$format" ]; then
-	LOCPATH=${common_objpfx}localedata \
-	GCONV_PATH=${common_objpfx}/iconvdata \
-	${run_program_prefix} ${common_objpfx}localedata/tst-fmon \
-	    "$locale" "$format" "$value" "$expect"
-	if [ $? -eq 0 ]; then
+	if LOCPATH=${common_objpfx}localedata \
+	   GCONV_PATH=${common_objpfx}/iconvdata \
+	   ${run_program_prefix} ${common_objpfx}localedata/tst-fmon \
+	   "$locale" "$format" "$value" "$expect" ; then
 	    echo "Locale: \"${locale}\" Format: \"${format}\"" \
 		 "Value: \"${value}\" Expect: \"${expect}\"  passed"
 	else
+	    errcode=$?
 	    echo "Locale: \"${locale}\" Format: \"${format}\"" \
 		 "Value: \"${value}\" Expect: \"${expect}\"    failed"
 	fi
     fi
 done < $datafile
 
-exit $?
+exit $errcode
 # Local Variables:
 #  mode:shell-script
 # End: