[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1361908016-3110-1-git-send-email-s.syam@samsung.com>
Date: Wed, 27 Feb 2013 01:16:56 +0530
From: Syam Sidhardhan <syamsidhardh@...il.com>
To: linux-mtd@...ts.infradead.org, linux-kernel@...r.kernel.org
Cc: syamsidhardh@...il.com, dwmw2@...radead.org
Subject: [PATCH] mtd: maps: Remove redundant NULL check before kfree
kfree on NULL pointer is a no-op.
Signed-off-by: Syam Sidhardhan <s.syam@...sung.com>
---
drivers/mtd/maps/ck804xrom.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/mtd/maps/ck804xrom.c b/drivers/mtd/maps/ck804xrom.c
index 586a1c7..0455166 100644
--- a/drivers/mtd/maps/ck804xrom.c
+++ b/drivers/mtd/maps/ck804xrom.c
@@ -308,8 +308,7 @@ static int ck804xrom_init_one(struct pci_dev *pdev,
out:
/* Free any left over map structures */
- if (map)
- kfree(map);
+ kfree(map);
/* See if I have any map structures */
if (list_empty(&window->maps)) {
--
1.7.9.5
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists