diff options
author | Ding Xiang <dingxiang@cmss.chinamobile.com> | 2019-05-29 15:18:22 +0800 |
---|---|---|
committer | Richard Weinberger <richard@nod.at> | 2019-07-07 20:31:29 +0200 |
commit | 63898ab5159f6349f58b23cbf9cd06a824d88527 (patch) | |
tree | 7ade4286ab3cf65600971d609006e850343818e0 /drivers | |
parent | 1d2af80d581d1bae81594e497cd57e345235b940 (diff) | |
download | linux-63898ab5159f6349f58b23cbf9cd06a824d88527.tar.bz2 |
mtd: afs: remove unneeded NULL check
NULL check before kfree is unneeded, so remove it.
Signed-off-by: Ding Xiang <dingxiang@cmss.chinamobile.com>
Signed-off-by: Richard Weinberger <richard@nod.at>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/mtd/parsers/afs.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/mtd/parsers/afs.c b/drivers/mtd/parsers/afs.c index f24d768eee30..752b6cf005f7 100644 --- a/drivers/mtd/parsers/afs.c +++ b/drivers/mtd/parsers/afs.c @@ -371,8 +371,7 @@ static int parse_afs_partitions(struct mtd_info *mtd, out_free_parts: while (i >= 0) { - if (parts[i].name) - kfree(parts[i].name); + kfree(parts[i].name); i--; } kfree(parts); |