mptcp.lists.linux.dev archive mirror
 help / color / mirror / Atom feed
* [PATCH mptcp-next] Squash to "selftests: mptcp: userspace pm address tests"
@ 2022-06-21  1:59 Geliang Tang
  2022-06-21  1:59 ` [PATCH mptcp-next] Squash to "selftests: mptcp: userspace pm subflow tests" Geliang Tang
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Geliang Tang @ 2022-06-21  1:59 UTC (permalink / raw)
  To: mptcp; +Cc: Geliang Tang

Use kill_wait() helper as Mat suggested.

Signed-off-by: Geliang Tang <geliang.tang@suse.com>
---
 tools/testing/selftests/net/mptcp/mptcp_join.sh | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/tools/testing/selftests/net/mptcp/mptcp_join.sh b/tools/testing/selftests/net/mptcp/mptcp_join.sh
index 977c59c540b2..d889e7507cd9 100755
--- a/tools/testing/selftests/net/mptcp/mptcp_join.sh
+++ b/tools/testing/selftests/net/mptcp/mptcp_join.sh
@@ -455,6 +455,12 @@ wait_mpj()
 	done
 }
 
+kill_wait()
+{
+	kill $1 > /dev/null 2>&1
+	wait $1 2>/dev/null
+}
+
 pm_nl_set_limits()
 {
 	local ns=$1
@@ -917,8 +923,7 @@ do_transfer()
 	fi
 
 	if [ $userspace_pm -eq 1 ]; then
-		kill $evts_ns1_pid
-		wait $evts_ns1_pid 2>/dev/null
+		kill_wait $evts_ns1_pid
 		rm -rf $evts_ns1
 	fi
 
-- 
2.35.3


^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2022-06-22 20:58 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-06-21  1:59 [PATCH mptcp-next] Squash to "selftests: mptcp: userspace pm address tests" Geliang Tang
2022-06-21  1:59 ` [PATCH mptcp-next] Squash to "selftests: mptcp: userspace pm subflow tests" Geliang Tang
2022-06-21 22:15 ` [PATCH mptcp-next] Squash to "selftests: mptcp: userspace pm address tests" Mat Martineau
2022-06-22 20:58 ` Matthieu Baerts

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).