Fix free space size check

SVN-Revision: 6880
This commit is contained in:
Eugene Konev 2007-04-07 10:36:31 +00:00
parent 5e42783559
commit 74c927577d

View File

@ -242,7 +242,7 @@ diff -ur linux.old/drivers/mtd/mtdpart.c linux.dev/drivers/mtd/mtdpart.c
+ part->offset += len; + part->offset += len;
+ part->size -= len; + part->size -= len;
+ +
+ if (len + master->erasesize < part->size) + if (master->erasesize <= part->size)
+ ret = add_mtd_partition(master, part, i + 1); + ret = add_mtd_partition(master, part, i + 1);
+ else + else
+ kfree(part->name); + kfree(part->name);