diff options
author | Dafydd Harries <dafydd.harries@collabora.co.uk> | 2007-02-13 15:07:00 +0000 |
---|---|---|
committer | Dafydd Harries <dafydd.harries@collabora.co.uk> | 2007-02-13 15:07:00 +0000 |
commit | 54f621930965360e165b2d47f0c4699ebbe68d8b (patch) | |
tree | 37cf3b15bebd8b5338f102f85d19dcf84f310c95 /scripts | |
parent | 708857c39d565395975c6826c8ab2aa4bf745415 (diff) | |
download | libnice-54f621930965360e165b2d47f0c4699ebbe68d8b.tar.gz |
valgrind.sh: fail if memory was definitely leaked
darcs-hash:20070213150736-c9803-2332896e51ee0d04d0e0814b568da5e68ea15af8.gz
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/valgrind.sh | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/scripts/valgrind.sh b/scripts/valgrind.sh index c5b1dbd..1e25875 100755 --- a/scripts/valgrind.sh +++ b/scripts/valgrind.sh @@ -4,7 +4,6 @@ export G_SLICE=always-malloc export G_DEBUG=gc-friendly report=`libtool --mode=execute valgrind \ - -q \ --leak-check=full \ --show-reachable=no \ --error-exitcode=1 \ @@ -15,3 +14,11 @@ if test $? != 0; then echo "$report" exit 1 fi + +if echo "$report" | grep -q "definitely lost"; then + if ! echo "$report" | grep -q "definitely lost: 0 bytes"; then + echo "$report" + exit 1 + fi +fi + |