Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

[IPV6]: Replace bogus instances of inet->recverr

While looking at this problem I noticed that IPv6 was sometimes
looking at inet->recverr which is bogus. Here is a patch to
correct that and use np->recverr.

Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Acked-by: Hideaki YOSHIFUJI <yoshfuji@linux-ipv6.org>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Herbert Xu and committed by
David S. Miller
3320da89 357b40a1

+3 -5
+1 -1
net/ipv6/ip6_output.c
··· 1149 1149 err = NF_HOOK(PF_INET6, NF_IP6_LOCAL_OUT, skb, NULL, skb->dst->dev, dst_output); 1150 1150 if (err) { 1151 1151 if (err > 0) 1152 - err = inet->recverr ? net_xmit_errno(err) : 0; 1152 + err = np->recverr ? net_xmit_errno(err) : 0; 1153 1153 if (err) 1154 1154 goto error; 1155 1155 }
+2 -4
net/ipv6/raw.c
··· 533 533 struct flowi *fl, struct rt6_info *rt, 534 534 unsigned int flags) 535 535 { 536 - struct inet_sock *inet = inet_sk(sk); 536 + struct ipv6_pinfo *np = inet6_sk(sk); 537 537 struct ipv6hdr *iph; 538 538 struct sk_buff *skb; 539 539 unsigned int hh_len; ··· 570 570 err = NF_HOOK(PF_INET6, NF_IP6_LOCAL_OUT, skb, NULL, rt->u.dst.dev, 571 571 dst_output); 572 572 if (err > 0) 573 - err = inet->recverr ? net_xmit_errno(err) : 0; 573 + err = np->recverr ? net_xmit_errno(err) : 0; 574 574 if (err) 575 575 goto error; 576 576 out: ··· 807 807 ip6_dst_store(sk, dst, 808 808 ipv6_addr_equal(&fl.fl6_dst, &np->daddr) ? 809 809 &np->daddr : NULL); 810 - if (err > 0) 811 - err = np->recverr ? net_xmit_errno(err) : 0; 812 810 813 811 release_sock(sk); 814 812 out: