[PATCH mptcp-next] Squash to "selftests: mptcp: update userspace pm add helpers"

Geliang Tang posted 1 patch 9 months, 3 weeks ago
Failed in applying to current master (apply log)
tools/testing/selftests/net/mptcp/mptcp_join.sh | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
[PATCH mptcp-next] Squash to "selftests: mptcp: update userspace pm add helpers"
Posted by Geliang Tang 9 months, 3 weeks ago
Use only one sed in evts_get_info.

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

diff --git a/tools/testing/selftests/net/mptcp/mptcp_join.sh b/tools/testing/selftests/net/mptcp/mptcp_join.sh
index a0912b1d6405..949c5cc0efcb 100755
--- a/tools/testing/selftests/net/mptcp/mptcp_join.sh
+++ b/tools/testing/selftests/net/mptcp/mptcp_join.sh
@@ -3255,11 +3255,10 @@ fail_tests()
 	fi
 }
 
-# $1: info name ; $2: ns ; $3: event type
+# $1: info name ; $2: evts_ns ; $3: event type
 evts_get_info()
 {
-	sed -n '/^type:'${3:-1}',/p' "${2}" |
-	sed -n 's/.*\('${1}':\)\([0-9a-f:.]*\).*$/\2/p;q'
+	sed -n 's/\(^type:'${3:-1}',\).*\('${1}':\)\([0-9a-f:.]*\).*$/\3/p' "${2}"
 }
 
 # $1: ns ; $2: addr ; $3: id
-- 
2.35.3