Subject: [PATCH iproute2] ss: adds a space before congestion string

From: Eric Dumazet <[email-masked]>
Date: Fri, 11 Sep 2009 10:32:29 +0200

Stephen Hemminger a écrit :
> I am putting together release for 2.6.31 based tools.
> The only open issue is how to deal with the error handling in commands
> that do monitoring filtering.  Right now leaning towards the two socket
> solution.
> 
> So if you have anything else that you have been waiting for,
> please drop me a note.

Another patch would be nice too :

ss -io

ESTAB      0      0                                         55.225.18.16:52668                                     55.225.18.187:49531
         sackbic wscale:2,6 rto:219 rtt:19.75/16.5 ato:40 cwnd:4 send 2.4Mbps rcv_space:5840

Note the 'sackbic' string, instead of sack bic ?

Thanks

[PATCH] ss: adds a space before congestion string

Signed-off-by: Eric Dumazet <[email-masked]>
---
diff --git a/misc/ss.c b/misc/ss.c
index 651fe3b..9396468 100644
--- a/misc/ss.c
+++ b/misc/ss.c
@@ -1302,7 +1302,7 @@ static void tcp_show_info(const struct nlmsghdr *nlh, struct inet_diag_msg *r)
 		}
 
 		if (tb[INET_DIAG_CONG])
-			printf("%s", (char *) RTA_DATA(tb[INET_DIAG_CONG]));
+			printf(" %s", (char *) RTA_DATA(tb[INET_DIAG_CONG]));
 
 		if (info->tcpi_options & TCPI_OPT_WSCALE)
 			printf(" wscale:%d,%d", info->tcpi_snd_wscale,