]> git.proxmox.com Git - qemu.git/commit
qcow2: Ignore reserved bits in get_cluster_offset
authorKevin Wolf <kwolf@redhat.com>
Wed, 14 Mar 2012 18:15:03 +0000 (19:15 +0100)
committerKevin Wolf <kwolf@redhat.com>
Fri, 20 Apr 2012 13:57:27 +0000 (15:57 +0200)
commit68d000a39074fe3888680491444a7fde2354cd84
tree8ac53ab1e3685e049cdceeb17ee0342da44a7bed
parent90b277593df873d3a2480f002e2eb5fe1f8e5277
qcow2: Ignore reserved bits in get_cluster_offset

With this change, reading from a qcow2 image ignores all reserved bits
that are set in an L1 or L2 table entry.

Now get_cluster_offset() assigns *cluster_offset only the offset without
any other flags. The cluster type is not longer encoded in the offset,
but a positive return value in case of success.

Signed-off-by: Kevin Wolf <kwolf@redhat.com>
block/qcow2-cluster.c
block/qcow2.c
block/qcow2.h