jffs2: remove unneeded kfree.
PATCH 1/1 jffs2: remove unneeded kfree.
c->oobbuf hasn't been kmalloced in jffs2_dataflash_setup, so there is no need to free it.
--- fs/jffs2/wbuf.c | 1 - 1 file changed, 1 deletion(-)
fs/jffs2/wbuf.c +0 -1
@@ -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 ; }
Signature · 1 line
1.8.3.1
Quoted 13 lines · fangwei
c->oobbufhasn't been kmalloced injffs2_dataflash_setup, so there is no need to free it.Signed-off-by Wei Fang <[email protected]>--- fs/jffs2/wbuf.c | 1 - 1 file changed, 1 deletion(-)fs/jffs2/wbuf.c +0
-0
fs/jffs2/wbuf.c int jffs2_dataflash_setup(struct jffs2_sb_info *c) { · line 1279
Quoted 7 lines
fs/jffs2/wbuf.c +0
-1@@ -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 ; }
Your patches are whitespace damaged and cannot be applied. Please fix your mailer and resend. Consider retesting by sending to yourself and try using git-am. If all else fails, git-send-email is your friend.
Thanks,
Brian
Hi Brian,
Sorry, my bad, I configed my editor with expandtab. I'll fix it and test it in my end, then resend it.
Thanks,
Wei
Quoted 30 lines · Brian Norris
Quoted 13 lines · fangwei
c->oobbufhasn't been kmalloced injffs2_dataflash_setup, so there is no need to free it.Signed-off-by Wei Fang <[email protected]>--- fs/jffs2/wbuf.c | 1 - 1 file changed, 1 deletion(-)fs/jffs2/wbuf.c +0
-0fs/jffs2/wbuf.c int jffs2_dataflash_setup(struct jffs2_sb_info *c) { · line 1279
Quoted 7 lines
fs/jffs2/wbuf.c +0
-1@@ -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 ; }Your patches are whitespace damaged and cannot be applied. Please fix your mailer and resend. Consider retesting by sending to yourself and try using git-am. If all else fails, git-send-email is your friend.
Thanks,
Brian