summaryrefslogtreecommitdiff
path: root/tools/testing
diff options
context:
space:
mode:
authorMatthieu Baerts <matthieu.baerts@tessares.net>2021-09-01 20:15:37 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2021-09-22 13:39:31 +0300
commit5d37e739f531c7b51801f9247523336d7bc20936 (patch)
tree97fa8de06fe1d4296c8e7b38457b79ef8b27a7cf /tools/testing
parente35820fb56415be6924bf552ec223ed5f347b4be (diff)
downloadlinux-5d37e739f531c7b51801f9247523336d7bc20936.tar.xz
selftests: mptcp: clean tmp files in simult_flows
[ Upstream commit bfd862a7e9318dd906844807a713d27cdd1a72b1 ] '$cin' and '$sin' variables are local to a function: they are then not available from the cleanup trap. Instead, we need to use '$large' and '$small' that are not local and defined just before setting the trap. Without this patch, running this script in a loop might cause a: write: No space left on device issue. Fixes: 1a418cb8e888 ("mptcp: simult flow self-tests") Acked-by: Paolo Abeni <pabeni@redhat.com> Signed-off-by: Matthieu Baerts <matthieu.baerts@tessares.net> Signed-off-by: Mat Martineau <mathew.j.martineau@linux.intel.com> Signed-off-by: Jakub Kicinski <kuba@kernel.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'tools/testing')
-rwxr-xr-xtools/testing/selftests/net/mptcp/simult_flows.sh4
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/testing/selftests/net/mptcp/simult_flows.sh b/tools/testing/selftests/net/mptcp/simult_flows.sh
index fd63ebfe9a2b..910d8126af8f 100755
--- a/tools/testing/selftests/net/mptcp/simult_flows.sh
+++ b/tools/testing/selftests/net/mptcp/simult_flows.sh
@@ -22,8 +22,8 @@ usage() {
cleanup()
{
- rm -f "$cin" "$cout"
- rm -f "$sin" "$sout"
+ rm -f "$cout" "$sout"
+ rm -f "$large" "$small"
rm -f "$capout"
local netns