]> Git Repo - qemu.git/commit - block/qcow2.h
qcow2: Return 0/-errno in qcow2_alloc_compressed_cluster_offset()
authorKevin Wolf <[email protected]>
Wed, 27 Feb 2019 09:26:24 +0000 (10:26 +0100)
committerKevin Wolf <[email protected]>
Fri, 8 Mar 2019 11:26:45 +0000 (12:26 +0100)
commit77e023ff79222191e8cc3d377504da8f19926837
treecb20fe92b89dd4dd24f840ddaa41c8026de3685d
parentc6d619cc12813acb2b1198f28cf2256ea9a30107
qcow2: Return 0/-errno in qcow2_alloc_compressed_cluster_offset()

qcow2_alloc_compressed_cluster_offset() used to return the cluster
offset for success and 0 for error. This doesn't only conflict with 0 as
a valid host offset, but also loses the error code.

Similar to the change made to qcow2_alloc_cluster_offset() for
uncompressed clusters in commit 148da7ea9d6, make the function return
0/-errno and return the allocated cluster offset in a by-reference
parameter.

Signed-off-by: Kevin Wolf <[email protected]>
block/qcow2-cluster.c
block/qcow2.c
block/qcow2.h
tests/qemu-iotests/220.out
This page took 0.028318 seconds and 4 git commands to generate.