patch-2.4.22 linux-2.4.22/net/ipv6/exthdrs.c
Next file: linux-2.4.22/net/ipv6/ip6_fib.c
Previous file: linux-2.4.22/net/ipv6/anycast.c
Back to the patch index
Back to the overall index
- Lines: 16
- Date:
2003-08-25 04:44:44.000000000 -0700
- Orig file:
linux-2.4.21/net/ipv6/exthdrs.c
- Orig date:
2003-06-13 07:51:39.000000000 -0700
diff -urN linux-2.4.21/net/ipv6/exthdrs.c linux-2.4.22/net/ipv6/exthdrs.c
@@ -235,8 +235,13 @@
return (&hdr->nexthdr) - skb->nh.raw;
}
- if (hdr->type != IPV6_SRCRT_TYPE_0 || (hdr->hdrlen & 0x01)) {
- icmpv6_param_prob(skb, ICMPV6_HDR_FIELD, hdr->type != IPV6_SRCRT_TYPE_0 ? 2 : 1);
+ if (hdr->type != IPV6_SRCRT_TYPE_0) {
+ icmpv6_param_prob(skb, ICMPV6_HDR_FIELD, (&hdr->type) - skb->nh.raw);
+ return -1;
+ }
+
+ if (hdr->hdrlen & 0x01) {
+ icmpv6_param_prob(skb, ICMPV6_HDR_FIELD, (&hdr->hdrlen) - skb->nh.raw);
return -1;
}
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)