Skip to content

Commit

Permalink
jffs2: remove unneeded kfree
Browse files Browse the repository at this point in the history
c->oobbuf hasn't been kmalloced in jffs2_dataflash_setup, so
there is no need to free it.

Signed-off-by: Wei Fang <[email protected]>
Signed-off-by: Brian Norris <[email protected]>
  • Loading branch information
FWei-HW authored and computersforpeace committed Sep 29, 2015
1 parent ecb43e0 commit 16c863b
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion fs/jffs2/wbuf.c
Original file line number Diff line number Diff line change
Expand Up @@ -1274,7 +1274,6 @@ int jffs2_dataflash_setup(struct jffs2_sb_info *c) {
#ifdef CONFIG_JFFS2_FS_WBUF_VERIFY
c->wbuf_verify = kmalloc(c->wbuf_pagesize, GFP_KERNEL);
if (!c->wbuf_verify) {
kfree(c->oobbuf);
kfree(c->wbuf);
return -ENOMEM;
}
Expand Down

0 comments on commit 16c863b

Please sign in to comment.