diff --git a/src/ch/ch_monitor.c b/src/ch/ch_monitor.c index 253a7d5be7c..7d7f255eb16 100644 --- a/src/ch/ch_monitor.c +++ b/src/ch/ch_monitor.c @@ -256,6 +256,11 @@ virCHMonitorBuildDiskJson(virJSONValuePtr disks, virDomainDiskDefPtr diskdef) diskdef->src->path != NULL && diskdef->src->type == VIR_STORAGE_TYPE_FILE) { disk = virJSONValueNewObject(); + if (diskdef->bus != VIR_DOMAIN_DISK_BUS_VIRTIO) { + virReportError(VIR_ERR_INVALID_ARG, + _("Only virtio bus types are supported for '%s'"), diskdef->src->path); + goto cleanup; + } if (!virFileExists(diskdef->src->path)) { virReportError(VIR_ERR_INVALID_ARG, _("failed to find disk '%s'"), diskdef->src->path);