瀏覽代碼

IPv6: fix Routing Header Type 0 handling thinko

Oops, thinko.  The test for accempting a RH0 was exatly the wrong way
around.

Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
YOSHIFUJI Hideaki 18 年之前
父節點
當前提交
a23cf14b16
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      net/ipv6/exthdrs.c

+ 1 - 1
net/ipv6/exthdrs.c

@@ -399,7 +399,7 @@ static int ipv6_rthdr_rcv(struct sk_buff **skbp)
 		break;
 		break;
 #endif
 #endif
 	case IPV6_SRCRT_TYPE_0:
 	case IPV6_SRCRT_TYPE_0:
-		if (accept_source_route <= 0)
+		if (accept_source_route > 0)
 			break;
 			break;
 		kfree_skb(skb);
 		kfree_skb(skb);
 		return -1;
 		return -1;