diff mbox series

[iproute2] ss: mptcp: fix add_addr_accepted stat print

Message ID a4925e2d0fa0e07a14bbef3744594d299e619249.1605708791.git.aclaudi@redhat.com (mailing list archive)
State New, archived
Delegated to: Stephen Hemminger
Headers show
Series [iproute2] ss: mptcp: fix add_addr_accepted stat print | expand

Checks

Context Check Description
netdev/tree_selection success Not a local patch

Commit Message

Andrea Claudi Nov. 18, 2020, 2:24 p.m. UTC
add_addr_accepted value is not printed if add_addr_signal value is 0.
Fix this properly looking for add_addr_accepted value, instead.

Fixes: 9c3be2c0eee01 ("ss: mptcp: add msk diag interface support")
Signed-off-by: Andrea Claudi <aclaudi@redhat.com>
---
 misc/ss.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Matthieu Baerts Nov. 18, 2020, 3:05 p.m. UTC | #1
Hi Andrea,

On 18/11/2020 15:24, Andrea Claudi wrote:
> add_addr_accepted value is not printed if add_addr_signal value is 0.
> Fix this properly looking for add_addr_accepted value, instead.

Good catch! We missed that when reviewing the code on MPTCP ML!

Acked-by: Matthieu Baerts <matthieu.baerts@tessares.net>

Cheers,
Matt
Stephen Hemminger Dec. 15, 2020, 9:59 p.m. UTC | #2
On Wed, 18 Nov 2020 15:24:18 +0100
Andrea Claudi <aclaudi@redhat.com> wrote:

> add_addr_accepted value is not printed if add_addr_signal value is 0.
> Fix this properly looking for add_addr_accepted value, instead.
> 
> Fixes: 9c3be2c0eee01 ("ss: mptcp: add msk diag interface support")
> Signed-off-by: Andrea Claudi <aclaudi@redhat.com>
> ---

Applied, this seems to have gotten lost somehow from patchwork.
diff mbox series

Patch

diff --git a/misc/ss.c b/misc/ss.c
index 77e1847ee2473..0593627b77e31 100644
--- a/misc/ss.c
+++ b/misc/ss.c
@@ -3136,7 +3136,7 @@  static void mptcp_stats_print(struct mptcp_info *s)
 		out(" subflows:%d", s->mptcpi_subflows);
 	if (s->mptcpi_add_addr_signal)
 		out(" add_addr_signal:%d", s->mptcpi_add_addr_signal);
-	if (s->mptcpi_add_addr_signal)
+	if (s->mptcpi_add_addr_accepted)
 		out(" add_addr_accepted:%d", s->mptcpi_add_addr_accepted);
 	if (s->mptcpi_subflows_max)
 		out(" subflows_max:%d", s->mptcpi_subflows_max);