tools/testbuild.sh: make sure fail get the real return error value

This commit is contained in:
liuhaitao 2020-02-08 11:40:29 +08:00 committed by Gregory Nutt
parent a8de37fbec
commit 48f1793a60
1 changed files with 3 additions and 2 deletions

View File

@ -151,8 +151,9 @@ cd $nuttx || { echo "ERROR: failed to CD to $nuttx"; exit 1; }
function makefunc { function makefunc {
${MAKE} $@ ${MAKE} $@
if [ $? != 0 ]; then ret=$?
fail=$? if [ $ret != 0 ]; then
fail=$ret
fi fi
} }