mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-27 18:03:50 +03:00
qemuDomainDefValidateDiskLunSource: Unbreak error messages
Simplify looking for the error messages. Signed-off-by: Peter Krempa <pkrempa@redhat.com> Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
This commit is contained in:
parent
fa8ce012a3
commit
5ccb39616f
@ -9840,15 +9840,13 @@ qemuDomainDefValidateDiskLunSource(const virStorageSource *src)
|
||||
if (virStorageSourceGetActualType(src) == VIR_STORAGE_TYPE_NETWORK) {
|
||||
if (src->protocol != VIR_STORAGE_NET_PROTOCOL_ISCSI) {
|
||||
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
|
||||
_("disk device='lun' is not supported "
|
||||
"for protocol='%s'"),
|
||||
_("disk device='lun' is not supported for protocol='%s'"),
|
||||
virStorageNetProtocolTypeToString(src->protocol));
|
||||
return -1;
|
||||
}
|
||||
} else if (!virStorageSourceIsBlockLocal(src)) {
|
||||
virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
|
||||
_("disk device='lun' is only valid for block "
|
||||
"type disk source"));
|
||||
_("disk device='lun' is only valid for block type disk source"));
|
||||
return -1;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user