]> git.ipfire.org Git - thirdparty/iproute2.git/commitdiff
iproute2: ss - change default filter to include all socket types
authorPetr Sabata <contyk@redhat.com>
Tue, 11 Dec 2012 06:42:52 +0000 (06:42 +0000)
committerStephen Hemminger <shemminger@vyatta.com>
Tue, 11 Dec 2012 17:50:39 +0000 (09:50 -0800)
Currently the default filter lists TCP sockets only which is
rather confusing especially when the '-a/--all' flag is used.
This patch changes the default to include all sockets, imitating
netstat(8) behavior.

Signed-off-by: Petr Ĺ abata <contyk@redhat.com>
Acked-by: David S. Miller <davem@davemloft.net>
misc/ss.c

index b45f5ba1bde53b2e9a4924d1ff997019a56b8f3f..b8cd60de20e751666eac71384592f6ebce28ae99 100644 (file)
--- a/misc/ss.c
+++ b/misc/ss.c
@@ -105,7 +105,7 @@ struct filter
 };
 
 struct filter default_filter = {
-       .dbs    =  (1<<TCP_DB),
+       .dbs    =  ~0,
        .states = SS_ALL & ~((1<<SS_LISTEN)|(1<<SS_CLOSE)|(1<<SS_TIME_WAIT)|(1<<SS_SYN_RECV)),
        .families= (1<<AF_INET)|(1<<AF_INET6),
 };