projects
/
GitHub
/
LineageOS
/
android_kernel_motorola_exynos9610.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ad66713
)
netfilter: log_arp: Use ARPHRD_ETHER instead of literal '1'
author
Gao Feng
<fgao@ikuai8.com>
Sun, 28 Aug 2016 13:41:22 +0000
(21:41 +0800)
committer
Pablo Neira Ayuso
<pablo@netfilter.org>
Tue, 30 Aug 2016 09:51:08 +0000
(11:51 +0200)
There is one macro ARPHRD_ETHER which defines the ethernet proto for ARP,
so we could use it instead of the literal number '1'.
Signed-off-by: Gao Feng <fgao@ikuai8.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
net/ipv4/netfilter/nf_log_arp.c
patch
|
blob
|
blame
|
history
diff --git
a/net/ipv4/netfilter/nf_log_arp.c
b/net/ipv4/netfilter/nf_log_arp.c
index e7ad950cf9ef9a7f7b4e92ac146e1f92f6c20c19..cf8f2d4e867a8dd0483b6397d2ba9f9f13619573 100644
(file)
--- a/
net/ipv4/netfilter/nf_log_arp.c
+++ b/
net/ipv4/netfilter/nf_log_arp.c
@@
-62,7
+62,7
@@
static void dump_arp_packet(struct nf_log_buf *m,
/* If it's for Ethernet and the lengths are OK, then log the ARP
* payload.
*/
- if (ah->ar_hrd != htons(
1
) ||
+ if (ah->ar_hrd != htons(
ARPHRD_ETHER
) ||
ah->ar_hln != ETH_ALEN ||
ah->ar_pln != sizeof(__be32))
return;