]> git.proxmox.com Git - mirror_qemu.git/commit
vvfat: fix qemu-img map and qemu-img convert
authorHervé Poussineau <hpoussin@reactos.org>
Mon, 22 May 2017 21:11:53 +0000 (23:11 +0200)
committerMichael Roth <mdroth@linux.vnet.ibm.com>
Thu, 3 Aug 2017 19:35:15 +0000 (14:35 -0500)
commit636eacb641ce747cbc87c0c878d807cc09b4f905
tree1b8eee133e01bc0b47837685b4cdf1ef7ce41a6d
parentc60a8ed89bcbccc48f4c9bd1088c0295019dec96
vvfat: fix qemu-img map and qemu-img convert

- bs->total_sectors is the number of sectors of the whole disk
- s->sector_count is the number of sectors of the FAT partition

This fixes the following assert in qemu-img map:
qemu-img.c:2641: get_block_status: Assertion `nb_sectors' failed.

This also fixes an infinite loop in qemu-img convert.

Fixes: 4480e0f924a42e1db8b8cfcac4d0634dd1bb27a0
Fixes: https://bugs.launchpad.net/qemu/+bug/1599539
Cc: qemu-stable@nongnu.org
Signed-off-by: Hervé Poussineau <hpoussin@reactos.org>
Reviewed-by: Eric Blake <eblake@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
(cherry picked from commit 139921aaa77c435104308ad53b631a00c3b65ae8)
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
block/vvfat.c