Skip to contentSkip to conversation

mtd: ndfc: fix a memory leak in ndfc_remove

PATCH Applied Axel Lin 2 participants 2 messages Jun 7, 2011 – Jun 8, 2011

Subsystems (2)
lore
Share & tools
lore

Axel Lin

author
#0 lore raw

PATCH 1/1 mtd: ndfc: fix a memory leak in ndfc_remove

---
 drivers/mtd/nand/ndfc.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
drivers/mtd/nand/ndfc.c +1 -0
index ea2dea8..7995470 100644
@@ -288,6 +288,7 @@ static int __devexit ndfc_remove(struct platform_device *ofdev)
 	struct ndfc_controller *ndfc = dev_get_drvdata(&ofdev->dev);
 
 	nand_release(&ndfc->mtd);
+	kfree(ndfc->mtd.name);
 
 	return 0;
 }
Signature · 1 line
1.7.4.1
#1 lore raw
Quoted 4 lines · Axel Lin
---
 drivers/mtd/nand/ndfc.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

Pushed to l2-mtd-2.6.git, thanks!

Signature · 2 lines
Best Regards,
Artem Bityutskiy (Артём Битюцкий)