diff options
author | Harvey Harrison <harvey.harrison@gmail.com> | 2008-10-31 00:54:29 -0700 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-10-31 00:54:29 -0700 |
commit | 14d5e834f6b36667c7da56374645f99b6cf30814 (patch) | |
tree | 14bfecb3f5b7eaeec508e8d069265a0583d6be9f /net/netfilter/xt_hashlimit.c | |
parent | 673d57e72398edfedc93fb50ff58048077c9d587 (diff) | |
download | linux-14d5e834f6b36667c7da56374645f99b6cf30814.tar.bz2 |
net: replace NIPQUAD() in net/netfilter/
Using NIPQUAD() with NIPQUAD_FMT, %d.%d.%d.%d or %u.%u.%u.%u
can be replaced with %pI4
Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/netfilter/xt_hashlimit.c')
-rw-r--r-- | net/netfilter/xt_hashlimit.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/net/netfilter/xt_hashlimit.c b/net/netfilter/xt_hashlimit.c index 6379717f9044..f97fded024c4 100644 --- a/net/netfilter/xt_hashlimit.c +++ b/net/netfilter/xt_hashlimit.c @@ -893,12 +893,11 @@ static int dl_seq_real_show(struct dsthash_ent *ent, u_int8_t family, switch (family) { case NFPROTO_IPV4: - return seq_printf(s, "%ld %u.%u.%u.%u:%u->" - "%u.%u.%u.%u:%u %u %u %u\n", + return seq_printf(s, "%ld %pI4:%u->%pI4:%u %u %u %u\n", (long)(ent->expires - jiffies)/HZ, - NIPQUAD(ent->dst.ip.src), + &ent->dst.ip.src, ntohs(ent->dst.src_port), - NIPQUAD(ent->dst.ip.dst), + &ent->dst.ip.dst, ntohs(ent->dst.dst_port), ent->rateinfo.credit, ent->rateinfo.credit_cap, ent->rateinfo.cost); |