diff options
author | Thomas Haller <thaller@redhat.com> | 2023-09-13 00:44:50 +0200 |
---|---|---|
committer | Florian Westphal <fw@strlen.de> | 2023-09-14 14:26:44 +0200 |
commit | 65d3e81ce8b98d0bde24f4d8c392c252981c7d8b (patch) | |
tree | 6b8c1bafbc403b791da10e7c3c9a40bf19c27c15 /tests/shell/helpers | |
parent | 35d437b7cc19d5126736e4820dcb38cfff051200 (diff) |
tests/shell: ensure vgdb-pipe files are deleted from "nft-valgrind-wrapper.sh"
When the valgrind process gets killed, those files can be left over.
They are located in the original $TMPDIR (usually /tmp). They should be
cleaned up.
I tried to cleanup the files from withing "nft-valgrind-wrapper.sh"
itself via a `trap`, but it doesn't work. Instead, let "run-tests.sh"
delete all files with a matching pattern.
Signed-off-by: Thomas Haller <thaller@redhat.com>
Signed-off-by: Florian Westphal <fw@strlen.de>
Diffstat (limited to 'tests/shell/helpers')
-rwxr-xr-x | tests/shell/helpers/nft-valgrind-wrapper.sh | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/shell/helpers/nft-valgrind-wrapper.sh b/tests/shell/helpers/nft-valgrind-wrapper.sh index 6125dd0f..98bbdf43 100755 --- a/tests/shell/helpers/nft-valgrind-wrapper.sh +++ b/tests/shell/helpers/nft-valgrind-wrapper.sh @@ -1,6 +1,6 @@ #!/bin/bash -e -SUFFIX="$(date "+%Y%m%d-%H%M%S.%6N.$$")" +SUFFIX="$(date "+%H%M%S.%6N").$$" rc=0 libtool \ @@ -12,7 +12,7 @@ libtool \ --show-leak-kinds=all \ --num-callers=100 \ --error-exitcode=122 \ - --vgdb-prefix="$NFT_TEST_TMPDIR_ORIG/vgdb-pipe-nft-test-$SUFFIX" \ + --vgdb-prefix="$_NFT_TEST_VALGRIND_VGDB_PREFIX-$SUFFIX" \ $NFT_TEST_VALGRIND_OPTS \ "$NFT_REAL" \ "$@" \ |