aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv4/raw.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/ipv4/raw.c')
-rw-r--r--net/ipv4/raw.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/net/ipv4/raw.c b/net/ipv4/raw.c
index 925fdf18cf92..7f39ea443ec8 100644
--- a/net/ipv4/raw.c
+++ b/net/ipv4/raw.c
@@ -320,6 +320,7 @@ static int raw_send_hdrinc(struct sock *sk, void *from, size_t length,
320 unsigned int flags) 320 unsigned int flags)
321{ 321{
322 struct inet_sock *inet = inet_sk(sk); 322 struct inet_sock *inet = inet_sk(sk);
323 struct net *net = sock_net(sk);
323 struct iphdr *iph; 324 struct iphdr *iph;
324 struct sk_buff *skb; 325 struct sk_buff *skb;
325 unsigned int iphlen; 326 unsigned int iphlen;
@@ -368,7 +369,7 @@ static int raw_send_hdrinc(struct sock *sk, void *from, size_t length,
368 iph->check = ip_fast_csum((unsigned char *)iph, iph->ihl); 369 iph->check = ip_fast_csum((unsigned char *)iph, iph->ihl);
369 } 370 }
370 if (iph->protocol == IPPROTO_ICMP) 371 if (iph->protocol == IPPROTO_ICMP)
371 icmp_out_count(((struct icmphdr *) 372 icmp_out_count(net, ((struct icmphdr *)
372 skb_transport_header(skb))->type); 373 skb_transport_header(skb))->type);
373 374
374 err = NF_HOOK(PF_INET, NF_INET_LOCAL_OUT, skb, NULL, rt->u.dst.dev, 375 err = NF_HOOK(PF_INET, NF_INET_LOCAL_OUT, skb, NULL, rt->u.dst.dev,