diff options
Diffstat (limited to 'net/ipv6/ipv6_sockglue.c')
-rw-r--r-- | net/ipv6/ipv6_sockglue.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/net/ipv6/ipv6_sockglue.c b/net/ipv6/ipv6_sockglue.c index a5eaaf693abf..4f3bb7fcc8b5 100644 --- a/net/ipv6/ipv6_sockglue.c +++ b/net/ipv6/ipv6_sockglue.c | |||
@@ -407,8 +407,16 @@ static int do_ipv6_setsockopt(struct sock *sk, int level, int optname, | |||
407 | /* routing header option needs extra check */ | 407 | /* routing header option needs extra check */ |
408 | if (optname == IPV6_RTHDR && opt->srcrt) { | 408 | if (optname == IPV6_RTHDR && opt->srcrt) { |
409 | struct ipv6_rt_hdr *rthdr = opt->srcrt; | 409 | struct ipv6_rt_hdr *rthdr = opt->srcrt; |
410 | if (rthdr->type) | 410 | switch (rthdr->type) { |
411 | case IPV6_SRCRT_TYPE_0: | ||
412 | #ifdef CONFIG_IPV6_MIP6 | ||
413 | case IPV6_SRCRT_TYPE_2: | ||
414 | #endif | ||
415 | break; | ||
416 | default: | ||
411 | goto sticky_done; | 417 | goto sticky_done; |
418 | } | ||
419 | |||
412 | if ((rthdr->hdrlen & 1) || | 420 | if ((rthdr->hdrlen & 1) || |
413 | (rthdr->hdrlen >> 1) != rthdr->segments_left) | 421 | (rthdr->hdrlen >> 1) != rthdr->segments_left) |
414 | goto sticky_done; | 422 | goto sticky_done; |