summaryrefslogtreecommitdiff
path: root/tests/run-stack-demangled-test.sh
diff options
context:
space:
mode:
authorMark Wielaard <mjw@redhat.com>2015-12-02 17:27:18 +0100
committerMark Wielaard <mjw@redhat.com>2016-01-02 20:37:45 +0100
commita5a354b9d7d4ca8c912945dd708ab465aec67c7f (patch)
treee05653b125492a22cff831051afcabc825c190d5 /tests/run-stack-demangled-test.sh
parent8bbfc552a062e47e307a897e49f2a4a25ba6291e (diff)
downloadelfutils-a5a354b9d7d4ca8c912945dd708ab465aec67c7f.tar.gz
tests: Use valgrind --leak-check=full.
When --enable-valgrind is given run the testsuite with --leak-check=full treating any memory leak as a failure. Also disable valgrind for those tests that trigger a valgrind bug. https://bugs.kde.org/show_bug.cgi?id=327427 Signed-off-by: Mark Wielaard <mjw@redhat.com>
Diffstat (limited to 'tests/run-stack-demangled-test.sh')
-rwxr-xr-xtests/run-stack-demangled-test.sh10
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/run-stack-demangled-test.sh b/tests/run-stack-demangled-test.sh
index 98f8ff8e..c26918f9 100755
--- a/tests/run-stack-demangled-test.sh
+++ b/tests/run-stack-demangled-test.sh
@@ -37,6 +37,11 @@ else
STACKCMD=${abs_top_builddir}/src/stack
fi
+# Disable valgrind while dumping because of a bug unmapping libc.so.
+# https://bugs.kde.org/show_bug.cgi?id=327427
+SAVED_VALGRIND_CMD="$VALGRIND_CMD"
+unset VALGRIND_CMD
+
# Without -d the top function comes out as fu.
testrun_compare ${abs_top_builddir}/src/stack -n 2 -e testfiledwarfinlines --core testfiledwarfinlines.core<<EOF
PID 13654 - core
@@ -92,4 +97,9 @@ TID 13654:
$STACKCMD: tid 13654: shown max number of frames (6, use -n 0 for unlimited)
EOF
+if [ "x$SAVED_VALGRIND_CMD" != "x" ]; then
+ VALGRIND_CMD="$SAVED_VALGRIND_CMD"
+ export VALGRIND_CMD
+fi
+
exit 0