qcow2: Fix image creation regression
authorKevin Wolf <kwolf@redhat.com>
Tue, 23 Feb 2010 15:06:20 +0000 (16:06 +0100)
committerAnthony Liguori <aliguori@us.ibm.com>
Tue, 23 Feb 2010 19:23:29 +0000 (13:23 -0600)
commit5a9d026449150c2a89099fe85f700a7b1437fd3a
tree98785dbac1d0a22e81ed51b4dccd7d623a246fb5
parente83b2d05494cf89b9e6b53548c27969acdbb7bfa
qcow2: Fix image creation regression

When checking for errors, commit db89119d compares with the wrong values,
failing image creation even when there was no error. Additionally, if an
error has occured, we can't preallocate the image (it's likely broken).

This unbreaks test 023 of qemu-iotests.

Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
block/qcow2.c