From ce9fff401a018793bd60ba52fd67fb8d09c34568 Mon Sep 17 00:00:00 2001 From: Felix Fietkau Date: Sun, 19 Aug 2007 01:06:26 +0000 Subject: fix an off-by-one error SVN-Revision: 8427 --- target/linux/generic-2.6/patches/065-block2mtd_init.patch | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'target/linux/generic-2.6/patches/065-block2mtd_init.patch') diff --git a/target/linux/generic-2.6/patches/065-block2mtd_init.patch b/target/linux/generic-2.6/patches/065-block2mtd_init.patch index 57a8615..bdb19ee 100644 --- a/target/linux/generic-2.6/patches/065-block2mtd_init.patch +++ b/target/linux/generic-2.6/patches/065-block2mtd_init.patch @@ -32,7 +32,7 @@ diff -urN linux-2.6.21.1.old/drivers/mtd/devices/block2mtd.c linux-2.6.21.1.dev/ + if (!mtdname) + mtdname = devname; + -+ dev->mtd.name = kmalloc(strlen(mtdname), GFP_KERNEL); ++ dev->mtd.name = kmalloc(strlen(mtdname) + 1, GFP_KERNEL); + if (!dev->mtd.name) goto devinit_err; -- cgit v1.1