vmx: Move error messages onto a single line

Error messages are exempt from the 80 columns rule. Move them
onto one line.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Pavel Hrdina <phrdina@redhat.com>
This commit is contained in:
Michal Privoznik 2023-08-24 17:03:59 +02:00
parent 9e47d4a657
commit 8a21339e63

View File

@ -938,8 +938,7 @@ virVMXSCSIDiskNameToControllerAndUnit(const char *name, int *controller, int *un
if (! STRPREFIX(name, "sd")) { if (! STRPREFIX(name, "sd")) {
virReportError(VIR_ERR_INTERNAL_ERROR, "%s", virReportError(VIR_ERR_INTERNAL_ERROR, "%s",
_("Expecting domain XML attribute 'dev' of entry " _("Expecting domain XML attribute 'dev' of entry 'devices/disk/target' to start with 'sd'"));
"'devices/disk/target' to start with 'sd'"));
return -1; return -1;
} }
@ -977,8 +976,7 @@ virVMXIDEDiskNameToBusAndUnit(const char *name, int *bus, int *unit)
if (! STRPREFIX(name, "hd")) { if (! STRPREFIX(name, "hd")) {
virReportError(VIR_ERR_INTERNAL_ERROR, "%s", virReportError(VIR_ERR_INTERNAL_ERROR, "%s",
_("Expecting domain XML attribute 'dev' of entry " _("Expecting domain XML attribute 'dev' of entry 'devices/disk/target' to start with 'hd'"));
"'devices/disk/target' to start with 'hd'"));
return -1; return -1;
} }
@ -1012,8 +1010,7 @@ virVMXFloppyDiskNameToUnit(const char *name, int *unit)
if (! STRPREFIX(name, "fd")) { if (! STRPREFIX(name, "fd")) {
virReportError(VIR_ERR_INTERNAL_ERROR, "%s", virReportError(VIR_ERR_INTERNAL_ERROR, "%s",
_("Expecting domain XML attribute 'dev' of entry " _("Expecting domain XML attribute 'dev' of entry 'devices/disk/target' to start with 'fd'"));
"'devices/disk/target' to start with 'fd'"));
return -1; return -1;
} }
@ -1505,8 +1502,7 @@ virVMXParseConfig(virVMXContext *ctx,
if (def->description != NULL) { if (def->description != NULL) {
if (virVMXUnescapeHexPipe(def->description) < 0) { if (virVMXUnescapeHexPipe(def->description) < 0) {
virReportError(VIR_ERR_INTERNAL_ERROR, "%s", virReportError(VIR_ERR_INTERNAL_ERROR, "%s",
_("VMX entry 'annotation' contains invalid escape " _("VMX entry 'annotation' contains invalid escape sequence"));
"sequence"));
goto cleanup; goto cleanup;
} }
} }
@ -1583,8 +1579,7 @@ virVMXParseConfig(virVMXContext *ctx,
cpu->sockets = numvcpus / coresPerSocket; cpu->sockets = numvcpus / coresPerSocket;
if (cpu->sockets <= 0) { if (cpu->sockets <= 0) {
virReportError(VIR_ERR_INTERNAL_ERROR, "%s", virReportError(VIR_ERR_INTERNAL_ERROR, "%s",
_("VMX entry 'cpuid.coresPerSocket' smaller than " _("VMX entry 'cpuid.coresPerSocket' smaller than 'numvcpus'"));
"'numvcpus'"));
goto cleanup; goto cleanup;
} }
cpu->dies = 1; cpu->dies = 1;
@ -3348,15 +3343,13 @@ virVMXFormatConfig(virVMXContext *ctx, virDomainXMLOption *xmlopt, virDomainDef
/* def:maxvcpus -> vmx:numvcpus */ /* def:maxvcpus -> vmx:numvcpus */
if (virDomainDefHasVcpusOffline(def)) { if (virDomainDefHasVcpusOffline(def)) {
virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
_("No support for domain XML entry 'vcpu' attribute " _("No support for domain XML entry 'vcpu' attribute 'current'"));
"'current'"));
goto cleanup; goto cleanup;
} }
maxvcpus = virDomainDefGetVcpusMax(def); maxvcpus = virDomainDefGetVcpusMax(def);
if (maxvcpus == 0) { if (maxvcpus == 0) {
virReportError(VIR_ERR_INTERNAL_ERROR, "%s", virReportError(VIR_ERR_INTERNAL_ERROR, "%s",
_("Expecting domain XML entry 'vcpu' to be greater " _("Expecting domain XML entry 'vcpu' to be greater than 0"));
"than 0"));
goto cleanup; goto cleanup;
} }