]> git.ipfire.org Git - thirdparty/qemu.git/commit
qcow2: Fix broken snapshot table entries
authorMax Reitz <mreitz@redhat.com>
Fri, 11 Oct 2019 15:28:08 +0000 (17:28 +0200)
committerMax Reitz <mreitz@redhat.com>
Mon, 28 Oct 2019 10:54:02 +0000 (11:54 +0100)
commitf91f1f159bcaa81a70e860079a73ae7d1220dc0c
tree6d4cd144994cfeb5a174259e922f93ca879bf29f
parentfe446b5da225b551fc6493890d437fe4a8ba7552
qcow2: Fix broken snapshot table entries

The only case where we currently reject snapshot table entries is when
they have too much extra data.  Fix them with qemu-img check -r all by
counting it as a corruption, reducing their extra_data_size, and then
letting qcow2_check_fix_snapshot_table() do the rest.

Signed-off-by: Max Reitz <mreitz@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Message-id: 20191011152814.14791-11-mreitz@redhat.com
Signed-off-by: Max Reitz <mreitz@redhat.com>
block/qcow2-snapshot.c