diff options
author | marcel <marcel@FreeBSD.org> | 2015-06-21 01:35:32 +0000 |
---|---|---|
committer | marcel <marcel@FreeBSD.org> | 2015-06-21 01:35:32 +0000 |
commit | 162b419db0120c29b07529d37bbb99ec2b79ffbd (patch) | |
tree | d381839e4f6328a596295f5dea3d074c017a28f0 /usr.bin | |
parent | 29dd35a1c65e2c5b8325855db8973cf442e1b146 (diff) | |
download | FreeBSD-src-162b419db0120c29b07529d37bbb99ec2b79ffbd.zip FreeBSD-src-162b419db0120c29b07529d37bbb99ec2b79ffbd.tar.gz |
Don't resize again prior to writing. Resizing may not be idempotent
and no scheme adjusts the size after the format resized the image
the first time.
Diffstat (limited to 'usr.bin')
-rw-r--r-- | usr.bin/mkimg/format.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/usr.bin/mkimg/format.c b/usr.bin/mkimg/format.c index 57bbd98..a21b08a 100644 --- a/usr.bin/mkimg/format.c +++ b/usr.bin/mkimg/format.c @@ -78,14 +78,10 @@ format_selected(void) int format_write(int fd) { - lba_t size; int error; if (format == NULL) return (ENOSYS); - size = image_get_size(); - error = format->resize(size); - if (!error) - error = format->write(fd); + error = format->write(fd); return (error); } |