Powered by Linux
[PATCH] testkernel.sh to retain make exit code — Semantic Matching Tool

[PATCH] testkernel.sh to retain make exit code

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Oleg Drokin <green@xxxxxxxxxxxxxx>

When running testkernel.sh from other scripts it's important
to know if the compile was a success or not.

Signed-off-by: Oleg Drokin <green@xxxxxxxxxxxxxx>
---
Recently I tied smatch into our gerrit so that people get head ups
on their patches before it gets to human inspectors (and hopefully
speeds up development that way).
And whenever I get a build failure, there's a false "all is fine"
message that should probably be avoided.

 smatch_scripts/test_kernel.sh | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/smatch_scripts/test_kernel.sh b/smatch_scripts/test_kernel.sh
index 4019169..f0cbb76 100755
--- a/smatch_scripts/test_kernel.sh
+++ b/smatch_scripts/test_kernel.sh
@@ -29,5 +29,7 @@ make clean
 find -name \*.c.smatch -exec rm \{\} \;
 make -j${NR_CPU} -k CHECK="$CMD -p=kernel --file-output $*" \
 	C=1 bzImage modules 2>&1 | tee smatch_compile.warns
+RETVAL=${PIPESTATUS[0]}
 find -name \*.c.smatch -exec cat \{\} \; -exec rm \{\} \; > smatch_warns.txt
 
+exit $RETVAL
-- 
2.1.0

--
To unsubscribe from this list: send the line "unsubscribe smatch" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux