Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

[NETFILTER]: SNMP NAT: fix memleak in snmp_object_decode

If kmalloc fails, error path leaks data allocated from asn1_oid_decode().

Signed-off-by: Chris Wright <chrisw@sous-sol.org>
Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Chris Wright and committed by
David S. Miller
4a063739 4d942d8b

+1
+1
net/ipv4/netfilter/ip_nat_snmp_basic.c
··· 768 768 len *= sizeof(unsigned long); 769 769 *obj = kmalloc(sizeof(struct snmp_object) + len, GFP_ATOMIC); 770 770 if (*obj == NULL) { 771 + kfree(lp); 771 772 kfree(id); 772 773 if (net_ratelimit()) 773 774 printk("OOM in bsalg (%d)\n", __LINE__);