From: Andres Salomon Date: Fri, 10 Dec 2010 08:41:14 +0000 (-0800) Subject: mkext3: fix sparse image creation X-Git-Url: https://spindle.queued.net/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9852f660c26f3454e291fc20c403dc7bf1386b85;p=xodist mkext3: fix sparse image creation Subtracting one from image size was creating problems with larger images. I don't know why, but it's an easy fix. Signed-off-by: Andres Salomon --- diff --git a/mkext3.sh b/mkext3.sh index 08a1c41..4e3a60a 100755 --- a/mkext3.sh +++ b/mkext3.sh @@ -65,7 +65,7 @@ create_bootable_img() # first, create a sparse image minus_size=$(($size * 6 / 100)) size=$(($size - $minus_size)) - dd if=/dev/zero of=$img bs=1M count=1 seek=$(($size - 1)) + dd if=/dev/zero of=$img bs=1M count=1 seek=$size # fill in the partition table parted -s "$img" "mklabel msdos"