summary refs log tree commit diff stats
path: root/scripts/render_block_graph.py
diff options
context:
space:
mode:
authorKevin Wolf <kwolf@redhat.com>2019-01-18 14:40:36 +0100
committerKevin Wolf <kwolf@redhat.com>2019-03-08 12:26:45 +0100
commitc6d619cc12813acb2b1198f28cf2256ea9a30107 (patch)
treeba8aed5c59a1a2b39eafc37750d3c82dd6f6e259 /scripts/render_block_graph.py
parentb8c8353a38296fbb92e05a2843e853c1ddfc2674 (diff)
downloadfocaccia-qemu-c6d619cc12813acb2b1198f28cf2256ea9a30107.tar.gz
focaccia-qemu-c6d619cc12813acb2b1198f28cf2256ea9a30107.zip
qcow2: Don't assume 0 is an invalid cluster offset
The cluster allocation code uses 0 as an invalid offset that is used in
case of errors or as "offset not yet determined". With external data
files, a host cluster offset of 0 becomes valid, though.

Define a constant INV_OFFSET (which is not cluster aligned and will
therefore never be a valid offset) that can be used for such purposes.

This removes the additional host_offset == 0 check that commit
ff52aab2df5 introduced; the confusion between an invalid offset and
(erroneous) allocation at offset 0 is removed with this change.

Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Diffstat (limited to 'scripts/render_block_graph.py')
0 files changed, 0 insertions, 0 deletions