• K
    qcow2: Fix order in L2 table COW · 16fde5f2
    Kevin Wolf 提交于
    When copying L2 tables (this happens only with internal snapshots), the order
    wasn't completely safe, so that after a crash you could end up with a L2 table
    that has too low refcount, possibly leading to corruption in the long run.
    
    This patch puts the operations in the right order: First allocate the new
    L2 table and replace the reference, and only then decrease the refcount of the
    old table.
    Signed-off-by: NKevin Wolf <kwolf@redhat.com>
    16fde5f2
qcow2-cluster.c 27.8 KB