aboutsummaryrefslogtreecommitdiff
path: root/block/qcow2.c
diff options
context:
space:
mode:
authorKevin Wolf <kwolf@redhat.com>2014-06-04 15:09:35 +0200
committerKevin Wolf <kwolf@redhat.com>2014-06-26 13:51:01 +0200
commit8ee79e707a005c9274df7ce34265bb7d008b8cef (patch)
treef8402fad14af55bef4457d8a5888db05d1d11fec /block/qcow2.c
parent76c591b013782217cad67b35c74cd249e0413439 (diff)
block: Catch backing files assigned to non-COW drivers
Since we parse backing.* options to add a backing file from the command line when the driver didn't assign one, it has been possible to have a backing file for e.g. raw images (it just was never accessed). This is obvious nonsense and should be rejected. Signed-off-by: Kevin Wolf <kwolf@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com>
Diffstat (limited to 'block/qcow2.c')
-rw-r--r--block/qcow2.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/block/qcow2.c b/block/qcow2.c
index b9d2fa6632..67e55c9667 100644
--- a/block/qcow2.c
+++ b/block/qcow2.c
@@ -2418,6 +2418,7 @@ static BlockDriver bdrv_qcow2 = {
.bdrv_save_vmstate = qcow2_save_vmstate,
.bdrv_load_vmstate = qcow2_load_vmstate,
+ .supports_backing = true,
.bdrv_change_backing_file = qcow2_change_backing_file,
.bdrv_refresh_limits = qcow2_refresh_limits,