projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5b5fde7
)
net: sctp_probe: simplify code by using %pISc format specifier
author
Daniel Borkmann
<
[email protected]
>
Thu, 22 Aug 2013 15:12:50 +0000
(17:12 +0200)
committer
David S. Miller
<
[email protected]
>
Fri, 23 Aug 2013 05:07:06 +0000
(22:07 -0700)
We can simply use the %pISc format specifier that was recently added
and thus remove some code that distinguishes between IPv4 and IPv6.
Signed-off-by: Daniel Borkmann <
[email protected]
>
Acked-by: Neil Horman <
[email protected]
>
Signed-off-by: David S. Miller <
[email protected]
>
net/sctp/probe.c
patch
|
blob
|
history
diff --git
a/net/sctp/probe.c
b/net/sctp/probe.c
index e62c22535be424cc53311dfc5b8f4540faa47e59..cd72ae57aff13e9b5f26b3ebba2109480bc0223d 100644
(file)
--- a/
net/sctp/probe.c
+++ b/
net/sctp/probe.c
@@
-155,13
+155,8
@@
static sctp_disposition_t jsctp_sf_eat_sack(struct net *net,
if (sp == asoc->peer.primary_path)
printl("*");
- if (sp->ipaddr.sa.sa_family == AF_INET)
- printl("%pI4 ", &sp->ipaddr.v4.sin_addr);
- else
- printl("%pI6 ", &sp->ipaddr.v6.sin6_addr);
-
- printl("%2u %8u %8u %8u %8u %8u ",
- sp->state, sp->cwnd, sp->ssthresh,
+ printl("%pISc %2u %8u %8u %8u %8u %8u ",
+ &sp->ipaddr, sp->state, sp->cwnd, sp->ssthresh,
sp->flight_size, sp->partial_bytes_acked,
sp->pathmtu);
}