fs/jffs2/scan.c: Fix error-path leak
PATCH 1/1 fs/jffs2/scan.c: Fix error-path leak
Description: Fix error-path leak in function jffs2_scan_medium(), in file fs/jffs2/scan.c
Signed-off-by Amit Choudhary <[email protected]>
fs/jffs2/scan.c +2 -0
@@ -130,6 +130,8 @@ #endifif (jffs2_sum_active ()) { s =kmalloc (sizeof (struct jffs2_summary ),GFP_KERNEL );if (!s) { +free (flashbuf); + flashbuf =NULL ;JFFS2_WARNING ("Can't allocate memory for summary\n" );return -ENOMEM ; }
Please, do not forget look at MAINTAINERS and CC the maintainer. David is CCed.
Quoted 23 lines · Amit Choudhary
Description: Fix error-path leak in function
jffs2_scan_medium(), in filefs/jffs2/scan.cSigned-off-by Amit Choudhary <[email protected]>fs/jffs2/scan.c +2
-1@@ -130,6 +130,8 @@ #endifif (jffs2_sum_active ()) { s =kmalloc (sizeof (struct jffs2_summary ),GFP_KERNEL );if (!s) { +free (flashbuf); + flashbuf =NULL ;JFFS2_WARNING ("Can't allocate memory for summary\n" );return -ENOMEM ; } -To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Signature · 2 lines
Best Regards, Artem Bityutskiy (Артём Битюцкий)