vpc: Fix size in fixed image creation
commitc70221df1f89953e85a3f1f96ceefbd6888bb55f
authorKevin Wolf <kwolf@redhat.com>
Wed, 11 Feb 2015 16:19:57 +0000 (11 17:19 +0100)
committerMichael Roth <mdroth@linux.vnet.ibm.com>
Mon, 9 Mar 2015 03:58:14 +0000 (8 22:58 -0500)
treeef6376d06edddfca6a66f26646d30381a7cdf1d3
parent07db6859abffa79db6290a5f9f4dfdf93148189f
vpc: Fix size in fixed image creation

If total_sectors is rounded to match the geometry, total_size needs to
be changed as well. Otherwise we end up with an image whose geometry
describes a disk larger than the image file, which doesn't end well.

Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Reviewed-by: Max Reitz <mreitz@redhat.com>
(cherry picked from commit c7dd631d482912fd615a9ef18a0e0691e7a84836)
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
block/vpc.c