summaryrefslogtreecommitdiffstats
path: root/net/ipv4/netfilter/ipt_LOG.c
diff options
context:
space:
mode:
authorHarvey Harrison2008-10-31 08:53:08 +0100
committerDavid S. Miller2008-10-31 08:53:08 +0100
commitcffee385d7f367e80b288abf4261256477f7760e (patch)
treeac4655a3883910236effe70b6169f70a5b804182 /net/ipv4/netfilter/ipt_LOG.c
parentpkt_sched: Add peek emulation for non-work-conserving qdiscs. (diff)
downloadkernel-qcow2-linux-cffee385d7f367e80b288abf4261256477f7760e.tar.gz
kernel-qcow2-linux-cffee385d7f367e80b288abf4261256477f7760e.tar.xz
kernel-qcow2-linux-cffee385d7f367e80b288abf4261256477f7760e.zip
net: replace NIPQUAD() in net/ipv4/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/ipv4/netfilter/ipt_LOG.c')
-rw-r--r--net/ipv4/netfilter/ipt_LOG.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/net/ipv4/netfilter/ipt_LOG.c b/net/ipv4/netfilter/ipt_LOG.c
index fc6ce04a3e35..4614a696f1b0 100644
--- a/net/ipv4/netfilter/ipt_LOG.c
+++ b/net/ipv4/netfilter/ipt_LOG.c
@@ -54,8 +54,8 @@ static void dump_packet(const struct nf_loginfo *info,
/* Important fields:
* TOS, len, DF/MF, fragment offset, TTL, src, dst, options. */
/* Max length: 40 "SRC=255.255.255.255 DST=255.255.255.255 " */
- printk("SRC=%u.%u.%u.%u DST=%u.%u.%u.%u ",
- NIPQUAD(ih->saddr), NIPQUAD(ih->daddr));
+ printk("SRC=%pI4 DST=%pI4 ",
+ &ih->saddr, &ih->daddr);
/* Max length: 46 "LEN=65535 TOS=0xFF PREC=0xFF TTL=255 ID=65535 " */
printk("LEN=%u TOS=0x%02X PREC=0x%02X TTL=%u ID=%u ",
@@ -262,8 +262,7 @@ static void dump_packet(const struct nf_loginfo *info,
break;
case ICMP_REDIRECT:
/* Max length: 24 "GATEWAY=255.255.255.255 " */
- printk("GATEWAY=%u.%u.%u.%u ",
- NIPQUAD(ich->un.gateway));
+ printk("GATEWAY=%pI4 ", &ich->un.gateway);
/* Fall through */
case ICMP_DEST_UNREACH:
case ICMP_SOURCE_QUENCH: