Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754876AbYKGXgl (ORCPT ); Fri, 7 Nov 2008 18:36:41 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1752567AbYKGX1G (ORCPT ); Fri, 7 Nov 2008 18:27:06 -0500 Received: from kroah.org ([198.145.64.141]:47661 "EHLO coco.kroah.org" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1753870AbYKGX1C (ORCPT ); Fri, 7 Nov 2008 18:27:02 -0500 Date: Fri, 7 Nov 2008 15:26:29 -0800 From: Greg KH To: linux-kernel@vger.kernel.org, stable@kernel.org Cc: Justin Forbes , Zwane Mwaikambo , "Theodore Ts'o" , Randy Dunlap , Dave Jones , Chuck Wolber , Chris Wedgwood , Michael Krufky , Chuck Ebbert , Domenico Andreoli , Willy Tarreau , Rodrigo Rubira Branco , Jake Edge , Eugene Teo , torvalds@linux-foundation.org, akpm@linux-foundation.org, alan@lxorguk.ukuu.org.uk, netfilter-devel@vger.kernel.org, Patrick McHardy , davem@davemloft.net, Ilpo Jarvinen Subject: [patch 15/16] netfilter: snmp nat leaks memory in case of failure Message-ID: <20081107232629.GP4282@kroah.com> References: <20081107231848.995297975@mini.kroah.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline; filename="netfilter-snmp-nat-leaks-memory-in-case-of-failure.patch" Content-Transfer-Encoding: 8bit In-Reply-To: <20081107232544.GA4282@kroah.com> User-Agent: Mutt/1.5.16 (2007-06-09) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1030 Lines: 34 2.6.25-stable review patch. If anyone has any objections, please let us know. ------------------ From: Ilpo J?rvinen netfilter: snmp nat leaks memory in case of failure Upstream commit 311670f3e: Signed-off-by: Ilpo Jarvinen Signed-off-by: Patrick McHardy --- net/ipv4/netfilter/nf_nat_snmp_basic.c | 1 + 1 file changed, 1 insertion(+) --- a/net/ipv4/netfilter/nf_nat_snmp_basic.c +++ b/net/ipv4/netfilter/nf_nat_snmp_basic.c @@ -742,6 +742,7 @@ static unsigned char snmp_object_decode( *obj = kmalloc(sizeof(struct snmp_object) + len, GFP_ATOMIC); if (*obj == NULL) { + kfree(p); kfree(id); if (net_ratelimit()) printk("OOM in bsalg (%d)\n", __LINE__); -- -- 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/