package/mtd: don't append jffs2 data multiple times
authorGabor Juhos <juhosg@openwrt.org>
Sat, 2 Jul 2011 08:38:00 +0000 (08:38 +0000)
committerGabor Juhos <juhosg@openwrt.org>
Sat, 2 Jul 2011 08:38:00 +0000 (08:38 +0000)
SVN-Revision: 27358

package/mtd/Makefile
package/mtd/src/mtd.c

index dd8b24a276e6b6ec2635878f737fa2c1ec9eddf3..f416d6bb1803d0281c6a0b7192764d4c995cb0c4 100644 (file)
@@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
 include $(INCLUDE_DIR)/kernel.mk
 
 PKG_NAME:=mtd
-PKG_RELEASE:=15
+PKG_RELEASE:=16
 
 PKG_BUILD_DIR := $(KERNEL_BUILD_DIR)/$(PKG_NAME)
 STAMP_PREPARED := $(STAMP_PREPARED)_$(call confvar,CONFIG_MTD_REDBOOT_PARTS)
index 7f5816539b2c14c7e9fd6d2c566aca193ba7ad9a..b33582668f0b448dbb61a6a529dbb50dc7e55c7f 100644 (file)
@@ -409,6 +409,9 @@ resume:
                                /* got an EOF marker - this is the place to add some jffs2 data */
                                skip = mtd_replace_jffs2(mtd, fd, e, jffs2file);
 
+                               /* don't add it again */
+                               jffs2file = NULL;
+
                                w += skip;
                                e += skip;
                                skip -= buflen;