+ mtd-potential-leak-in-rfd_ftl_add_mtd.patch added to -mm tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The patch titled
     MTD: potential leak in rfd_ftl_add_mtd
has been added to the -mm tree.  Its filename is
     mtd-potential-leak-in-rfd_ftl_add_mtd.patch

*** Remember to use Documentation/SubmitChecklist when testing your code ***

See http://www.zip.com.au/~akpm/linux/patches/stuff/added-to-mm.txt to find
out what to do about this

------------------------------------------------------
Subject: MTD: potential leak in rfd_ftl_add_mtd
From: Florin Malita <fmalita@xxxxxxxxx>

This fixes a leak in the !mtd->erasesize error path (Coverity 1765).

Signed-off-by: Florin Malita <fmalita@xxxxxxxxx>
Cc: David Woodhouse <dwmw2@xxxxxxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
---

 drivers/mtd/rfd_ftl.c |    1 +
 1 files changed, 1 insertion(+)

diff -puN drivers/mtd/rfd_ftl.c~mtd-potential-leak-in-rfd_ftl_add_mtd drivers/mtd/rfd_ftl.c
--- a/drivers/mtd/rfd_ftl.c~mtd-potential-leak-in-rfd_ftl_add_mtd
+++ a/drivers/mtd/rfd_ftl.c
@@ -779,6 +779,7 @@ static void rfd_ftl_add_mtd(struct mtd_b
 	else {
 		if (!mtd->erasesize) {
 			printk(KERN_WARNING PREFIX "please provide block_size");
+			kfree(part);
 			return;
 		}
 		else
_

Patches currently in -mm which might be from fmalita@xxxxxxxxx are

origin.patch
mtd-potential-leak-in-rfd_ftl_add_mtd.patch

-
To unsubscribe from this list: send the line "unsubscribe mm-commits" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Kernel Newbies FAQ]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Photo]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux