diff options
author | Peter Wu <peter@lekensteyn.nl> | 2015-01-06 18:48:15 +0100 |
---|---|---|
committer | Kevin Wolf <kwolf@redhat.com> | 2015-02-06 17:24:21 +0100 |
commit | 177b75104da3e3a9af84975c32a44782d903c41f (patch) | |
tree | a7c059a84c67cf93249d0ef8058fc47f964d878c /arch_init.c | |
parent | 6b383c08c46468ecee98ecf71ffd8362e9bd7f42 (diff) | |
download | qemu-177b75104da3e3a9af84975c32a44782d903c41f.zip qemu-177b75104da3e3a9af84975c32a44782d903c41f.tar.gz qemu-177b75104da3e3a9af84975c32a44782d903c41f.tar.bz2 |
block/dmg: improve zeroes handling
Disk images may contain large all-zeroes gaps (1.66k sectors or 812 MiB
is seen in the real world). These blocks (type 2) do not need to be
extracted into a temporary buffer, there is no need to allocate memory
for these blocks nor to check its length.
(For the test image, the maximum uncompressed size is 1054371 bytes,
probably for a bzip2-compressed block.)
Signed-off-by: Peter Wu <peter@lekensteyn.nl>
Reviewed-by: John Snow <jsnow@redhat.com>
Message-id: 1420566495-13284-13-git-send-email-peter@lekensteyn.nl
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Diffstat (limited to 'arch_init.c')
0 files changed, 0 insertions, 0 deletions