提交 48396413 编写于 作者: D David Woodhouse

jffs2: fix another potential leak on error path in scan.c

Signed-off-by: NDavid Woodhouse <David.Woodhouse@intel.com>
上级 ac1b7c37
......@@ -130,9 +130,9 @@ int jffs2_scan_medium(struct jffs2_sb_info *c)
if (jffs2_sum_active()) {
s = kzalloc(sizeof(struct jffs2_summary), GFP_KERNEL);
if (!s) {
kfree(flashbuf);
JFFS2_WARNING("Can't allocate memory for summary\n");
return -ENOMEM;
ret = -ENOMEM;
goto out;
}
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册