Skip to content

Commit

Permalink
tgupdate: merge t/selftests-mptcp-pm_nl_ctl-always-look-for-errors ba…
Browse files Browse the repository at this point in the history
…se into t/selftests-mptcp-pm_nl_ctl-always-look-for-errors
  • Loading branch information
matttbe committed Jul 28, 2023
2 parents bb18446 + da221d3 commit 8353de0
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions tools/testing/selftests/net/mptcp/mptcp_join.sh
Original file line number Diff line number Diff line change
Expand Up @@ -761,6 +761,7 @@ pm_nl_del_endpoint()
local addr=$3

if [ $ip_mptcp -eq 1 ]; then
[ $id -ne 0 ] && addr=''
ip -n $ns mptcp endpoint delete id $id $addr
else
ip netns exec $ns ./pm_nl_ctl del $id $addr
Expand Down Expand Up @@ -846,10 +847,11 @@ pm_nl_check_endpoint()
fi

if [ $ip_mptcp -eq 1 ]; then
# get line and trim trailing whitespace
line=$(ip -n $ns mptcp endpoint show $id)
line="${line% }"
# the dump order is: address id flags port dev
expected_line="$addr"
[ -n "$addr" ] && expected_line="$expected_line $addr"
[ -n "$addr" ] && expected_line="$addr"
expected_line="$expected_line $id"
[ -n "$_flags" ] && expected_line="$expected_line ${_flags//","/" "}"
[ -n "$dev" ] && expected_line="$expected_line $dev"
Expand Down

0 comments on commit 8353de0

Please sign in to comment.