]> git.kernelconcepts.de Git - karo-tx-linux.git/commit
ipv4: raw: fix icmp_filter()
authorEric Dumazet <edumazet@google.com>
Sat, 22 Sep 2012 00:08:29 +0000 (00:08 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 12 Oct 2012 20:38:44 +0000 (05:38 +0900)
commit514ddfedb89c19c57de82aedec8da2bd8ff3802c
tree4a7c2c137effec29e674f73153a82f394612aa21
parent09c6cf7f980f1e8dbf58dc9ae0ebf4f6eb93cc0d
ipv4: raw: fix icmp_filter()

[ Upstream commit ab43ed8b7490cb387782423ecf74aeee7237e591 ]

icmp_filter() should not modify its input, or else its caller
would need to recompute ip_hdr() if skb->head is reallocated.

Use skb_header_pointer() instead of pskb_may_pull() and
change the prototype to make clear both sk and skb are const.

Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
net/ipv4/raw.c