r8884: valgrind error logs only matter if non-zero in size
authorAndrew Tridgell <tridge@samba.org>
Mon, 1 Aug 2005 16:12:21 +0000 (16:12 +0000)
committerGerald (Jerry) Carter <jerry@samba.org>
Wed, 10 Oct 2007 18:30:15 +0000 (13:30 -0500)
source/script/tests/selftest.sh

index 664fca18190cc73e2858c97fdb62f2069bd12ee1..17e991cc72a58a73077e5a9ef246da5a05cdc386 100755 (executable)
@@ -152,9 +152,11 @@ echo "END:   $END ($0)";
 list=`find $PREFIX -name 'valgrind.log*'`
 if [ x$list != x ]; then
     for f in $PREFIX/valgrind.log*; do
-       echo "VALGRIND FAILURE";
-       failed=`expr $failed + 1`
-       cat $f
+       if [ -s $f ]; then
+           echo "VALGRIND FAILURE";
+           failed=`expr $failed + 1`
+           cat $f
+       fi
     done
 fi