Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1762298AbXLMGth (ORCPT ); Thu, 13 Dec 2007 01:49:37 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1760146AbXLMGil (ORCPT ); Thu, 13 Dec 2007 01:38:41 -0500 Received: from pentafluge.infradead.org ([213.146.154.40]:56696 "EHLO pentafluge.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1760126AbXLMGik (ORCPT ); Thu, 13 Dec 2007 01:38:40 -0500 Date: Wed, 12 Dec 2007 22:35:34 -0800 From: Greg KH To: linux-kernel@vger.kernel.org, stable@kernel.org, Greg KH Cc: Justin Forbes , Zwane Mwaikambo , "Theodore Ts'o" , Randy Dunlap , Dave Jones , Chuck Wolber , Chris Wedgwood , Michael Krufky , Chuck Ebbert , Domenico Andreoli , torvalds@linux-foundation.org, akpm@linux-foundation.org, alan@lxorguk.ukuu.org.uk, davem@davemloft.net, Patrick McHardy , Herbert Xu Subject: [patch 34/36] NETFILTER: xt_TCPMSS: remove network triggerable WARN_ON Message-ID: <20071213063534.GI25301@kroah.com> References: <20071213062511.265908583@mini.kroah.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline; filename="netfilter-xt_tcpmss-remove-network-triggerable-warn_on.patch" In-Reply-To: <20071213063308.GA25301@kroah.com> User-Agent: Mutt/1.5.16 (2007-06-09) X-Bad-Reply: References and In-Reply-To but no 'Re:' in Subject. Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1249 Lines: 42 2.6.22-stable review patch. If anyone has any objections, please let us know. ------------------ From: Patrick McHardy [NETFILTER]: xt_TCPMSS: remove network triggerable WARN_ON [ Upstream commit: 9dc0564e862b1b9a4677dec2c736b12169e03e99 ] ipv6_skip_exthdr() returns -1 for invalid packets. don't WARN_ON that. Signed-off-by: Patrick McHardy Signed-off-by: Herbert Xu Signed-off-by: Greg Kroah-Hartman --- net/netfilter/xt_TCPMSS.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) --- a/net/netfilter/xt_TCPMSS.c +++ b/net/netfilter/xt_TCPMSS.c @@ -178,10 +178,8 @@ xt_tcpmss_target6(struct sk_buff **pskb, nexthdr = ipv6h->nexthdr; tcphoff = ipv6_skip_exthdr(*pskb, sizeof(*ipv6h), &nexthdr); - if (tcphoff < 0) { - WARN_ON(1); + if (tcphoff < 0) return NF_DROP; - } ret = tcpmss_mangle_packet(pskb, targinfo, tcphoff, sizeof(*ipv6h) + sizeof(struct tcphdr)); if (ret < 0) -- -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/