* [PATCH] netfilter/ipv4: snmp nat leaks memory in case of failure
@ 2008-10-16 9:19 Ilpo Järvinen
2008-10-16 12:02 ` Patrick McHardy
0 siblings, 1 reply; 2+ messages in thread
From: Ilpo Järvinen @ 2008-10-16 9:19 UTC (permalink / raw)
To: David Miller; +Cc: Patrick Hardy, Netdev
[-- Attachment #1: Type: TEXT/PLAIN, Size: 675 bytes --]
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@helsinki.fi>
---
net/ipv4/netfilter/nf_nat_snmp_basic.c | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/net/ipv4/netfilter/nf_nat_snmp_basic.c b/net/ipv4/netfilter/nf_nat_snmp_basic.c
index ffeaffc..8303e4b 100644
--- 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(struct asn1_ctx *ctx,
*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__);
--
1.5.2.2
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] netfilter/ipv4: snmp nat leaks memory in case of failure
2008-10-16 9:19 [PATCH] netfilter/ipv4: snmp nat leaks memory in case of failure Ilpo Järvinen
@ 2008-10-16 12:02 ` Patrick McHardy
0 siblings, 0 replies; 2+ messages in thread
From: Patrick McHardy @ 2008-10-16 12:02 UTC (permalink / raw)
To: Ilpo Järvinen; +Cc: David Miller, Netdev
Ilpo Järvinen wrote:
Applied, thanks Ilpo.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2008-10-16 12:02 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-10-16 9:19 [PATCH] netfilter/ipv4: snmp nat leaks memory in case of failure Ilpo Järvinen
2008-10-16 12:02 ` Patrick McHardy
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).