[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v2] qcow2: Zero-initialise first cluster for new
From: |
Stefan Hajnoczi |
Subject: |
Re: [Qemu-devel] [PATCH v2] qcow2: Zero-initialise first cluster for new images |
Date: |
Wed, 4 Dec 2013 11:29:40 +0100 |
User-agent: |
Mutt/1.5.21 (2010-09-15) |
On Wed, Dec 04, 2013 at 11:06:36AM +0100, Kevin Wolf wrote:
> Strictly speaking, this is only required for has_zero_init() == false,
> but it's easy enough to just do a cluster-aligned write that is padded
> with zeros after the header.
>
> This fixes that after 'qemu-img create' header extensions are attempted
> to be parsed that are really just random leftover data.
>
> Cc: address@hidden
> Signed-off-by: Kevin Wolf <address@hidden>
> Reviewed-by: Fam Zheng <address@hidden>
> Reviewed-by: Paolo Bonzini <address@hidden>
> ---
> block/qcow2.c | 36 ++++++++++++++++++++----------------
> 1 file changed, 20 insertions(+), 16 deletions(-)
Thanks, applied to my block tree:
https://github.com/stefanha/qemu/commits/block
Stefan