mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-03-07 17:28:15 +00:00
libxl: 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:
parent
0e588509f2
commit
e0420aeda5
@ -1284,8 +1284,7 @@ libxlMakeNic(virDomainDef *def,
|
||||
if (l_nic->script && !(actual_type == VIR_DOMAIN_NET_TYPE_BRIDGE ||
|
||||
actual_type == VIR_DOMAIN_NET_TYPE_ETHERNET)) {
|
||||
virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
|
||||
_("specifying a script is only supported with "
|
||||
"interface types bridge and ethernet"));
|
||||
_("specifying a script is only supported with interface types bridge and ethernet"));
|
||||
return -1;
|
||||
}
|
||||
|
||||
@ -1310,8 +1309,7 @@ libxlMakeNic(virDomainDef *def,
|
||||
def->os.type == VIR_DOMAIN_OSTYPE_XENPVH) &&
|
||||
l_nic->model != VIR_DOMAIN_NET_MODEL_NETFRONT) {
|
||||
virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
|
||||
_("only model 'netfront' is supported for "
|
||||
"Xen PV(H) domains"));
|
||||
_("only model 'netfront' is supported for Xen PV(H) domains"));
|
||||
return -1;
|
||||
}
|
||||
x_nic->model = g_strdup(virDomainNetGetModelString(l_nic));
|
||||
@ -1802,14 +1800,12 @@ libxlDriverConfigInit(libxlDriverConfig *cfg)
|
||||
}
|
||||
|
||||
if (libxl_ctx_alloc(&cfg->ctx, LIBXL_VERSION, 0, (xentoollog_logger *)cfg->logger)) {
|
||||
VIR_ERROR(_("cannot initialize libxenlight context, probably not "
|
||||
"running in a Xen Dom0, disabling driver"));
|
||||
VIR_ERROR(_("cannot initialize libxenlight context, probably not running in a Xen Dom0, disabling driver"));
|
||||
return -1;
|
||||
}
|
||||
|
||||
if ((cfg->verInfo = libxl_get_version_info(cfg->ctx)) == NULL) {
|
||||
VIR_ERROR(_("cannot version information from libxenlight, "
|
||||
"disabling driver"));
|
||||
VIR_ERROR(_("cannot version information from libxenlight, disabling driver"));
|
||||
return -1;
|
||||
}
|
||||
cfg->version = (cfg->verInfo->xen_version_major * 1000000) +
|
||||
|
@ -2904,8 +2904,7 @@ libxlDomainUndefineFlags(virDomainPtr dom,
|
||||
}
|
||||
} else {
|
||||
virReportError(VIR_ERR_OPERATION_INVALID, "%s",
|
||||
_("Refusing to undefine while domain managed "
|
||||
"save image exists"));
|
||||
_("Refusing to undefine while domain managed save image exists"));
|
||||
goto cleanup;
|
||||
}
|
||||
}
|
||||
@ -3212,8 +3211,7 @@ libxlDomainAttachHostUSBDevice(libxlDriverPrivate *driver,
|
||||
|
||||
if (libxlDomainAttachControllerDevice(driver, vm, controller) < 0) {
|
||||
virReportError(VIR_ERR_INTERNAL_ERROR, "%s",
|
||||
_("No available USB controller and port, and "
|
||||
"failed to attach a new one"));
|
||||
_("No available USB controller and port, and failed to attach a new one"));
|
||||
virDomainControllerDefFree(controller);
|
||||
goto cleanup;
|
||||
}
|
||||
|
@ -679,8 +679,7 @@ libxlDomainMigrationDstPrepare(virConnectPtr dconn,
|
||||
|
||||
if (STRPREFIX(hostname, "localhost")) {
|
||||
virReportError(VIR_ERR_INTERNAL_ERROR, "%s",
|
||||
_("hostname on destination resolved to localhost,"
|
||||
" but migration requires an FQDN"));
|
||||
_("hostname on destination resolved to localhost, but migration requires an FQDN"));
|
||||
goto endjob;
|
||||
}
|
||||
|
||||
@ -1142,8 +1141,7 @@ libxlDomainMigrationSrcPerformP2P(libxlDriverPrivate *driver,
|
||||
if (useParams <= 0) {
|
||||
if (useParams == 0)
|
||||
virReportError(VIR_ERR_OPERATION_FAILED, "%s",
|
||||
_("Destination libvirt does not support migration"
|
||||
" with extensible parameters"));
|
||||
_("Destination libvirt does not support migration with extensible parameters"));
|
||||
goto cleanup;
|
||||
}
|
||||
|
||||
@ -1260,9 +1258,8 @@ libxlDomainMigrationDstFinish(virConnectPtr dconn,
|
||||
/* Check if domain is alive */
|
||||
if (!virDomainObjIsActive(vm)) {
|
||||
/* Migration failed if domain is inactive */
|
||||
virReportError(VIR_ERR_OPERATION_FAILED,
|
||||
"%s", _("Migration failed. Domain is not running "
|
||||
"on destination host"));
|
||||
virReportError(VIR_ERR_OPERATION_FAILED, "%s",
|
||||
_("Migration failed. Domain is not running on destination host"));
|
||||
goto cleanup;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user