[PATCH 00/27] Move error messages onto a single line

This is inspired by the following discussion: https://listman.redhat.com/archives/libvir-list/2023-August/241361.html And ideally I'd present a green pipeline but for some reason, I can't: https://gitlab.com/MichalPrivoznik/libvirt/-/pipelines/981105262 But the problem is not with my code rather than our CI. Michal Prívozník (27): bhyve: Move error messages onto a single line ch: Move error messages onto a single line conf: Move error messages onto a single line cpu: Move error messages onto a single line esx: Move error messages onto a single line hypervisor: Move error messages onto a single line libxl: Move error messages onto a single line locking: Move error messages onto a single line lxc: Move error messages onto a single line network: Move error messages onto a single line node_device: Move error messages onto a single line nwfilter: Move error messages onto a single line openvz: Move error messages onto a single line qemu: Move error messages onto a single line remote: Move error messages onto a single line rpc: Move error messages onto a single line security: Move error messages onto a single line storage: Move error messages onto a single line storage_file: Move error messages onto a single line test: Move error messages onto a single line util: Move error messages onto a single line vbox: Move error messages onto a single line vmware: Move error messages onto a single line vmx: Move error messages onto a single line vz: Move error messages onto a single line src: Move error messages onto a single line tools: Move error messages onto a single line src/bhyve/bhyve_command.c | 31 +-- src/bhyve/bhyve_domain.c | 3 +- src/bhyve/bhyve_driver.c | 3 +- src/ch/ch_driver.c | 3 +- src/ch/ch_monitor.c | 3 +- src/conf/cpu_conf.c | 9 +- src/conf/domain_addr.c | 3 +- src/conf/domain_conf.c | 138 ++++-------- src/conf/domain_validate.c | 54 ++--- src/conf/netdev_bandwidth_conf.c | 3 +- src/conf/netdev_vlan_conf.c | 6 +- src/conf/network_conf.c | 27 +-- src/conf/node_device_conf.c | 3 +- src/conf/node_device_util.c | 3 +- src/conf/numa_conf.c | 25 +-- src/conf/nwfilter_params.c | 6 +- src/conf/snapshot_conf.c | 3 +- src/conf/storage_adapter_conf.c | 18 +- src/conf/virdomainjob.c | 3 +- src/conf/virnetworkobj.c | 3 +- src/cpu/cpu_x86.c | 6 +- src/esx/esx_driver.c | 21 +- src/esx/esx_network_driver.c | 3 +- src/esx/esx_storage_backend_vmfs.c | 3 +- src/esx/esx_util.c | 3 +- src/esx/esx_vi.c | 19 +- src/esx/esx_vi_types.c | 3 +- src/hypervisor/domain_cgroup.c | 3 +- src/hypervisor/virhostdev.c | 9 +- src/libvirt-domain.c | 54 ++--- src/libxl/libxl_conf.c | 12 +- src/libxl/libxl_driver.c | 6 +- src/libxl/libxl_migration.c | 11 +- src/locking/lock_driver_sanlock.c | 3 +- src/lxc/lxc_container.c | 3 +- src/lxc/lxc_driver.c | 3 +- src/lxc/lxc_native.c | 3 +- src/lxc/lxc_process.c | 3 +- src/network/bridge_driver.c | 14 +- src/network/bridge_driver_linux.c | 10 +- src/node_device/node_device_udev.c | 3 +- src/nwfilter/nwfilter_dhcpsnoop.c | 12 +- src/nwfilter/nwfilter_learnipaddr.c | 8 +- src/openvz/openvz_driver.c | 3 +- src/qemu/qemu_agent.c | 18 +- src/qemu/qemu_capabilities.c | 45 ++-- src/qemu/qemu_command.c | 42 ++-- src/qemu/qemu_conf.c | 5 +- src/qemu/qemu_domain.c | 51 ++--- src/qemu/qemu_domain_address.c | 15 +- src/qemu/qemu_driver.c | 120 ++++------ src/qemu/qemu_hostdev.c | 3 +- src/qemu/qemu_hotplug.c | 18 +- src/qemu/qemu_migration.c | 48 ++-- src/qemu/qemu_migration_params.c | 6 +- src/qemu/qemu_monitor.c | 3 +- src/qemu/qemu_monitor_json.c | 102 +++------ src/qemu/qemu_process.c | 20 +- src/qemu/qemu_snapshot.c | 27 +-- src/qemu/qemu_tpm.c | 4 +- src/qemu/qemu_validate.c | 209 ++++++------------ src/remote/remote_daemon.c | 3 +- src/remote/remote_driver.c | 27 +-- src/remote/remote_sockets.c | 3 +- src/rpc/virnetclient.c | 9 +- src/rpc/virnetlibsshsession.c | 28 +-- src/rpc/virnetserver.c | 9 +- src/rpc/virnetserverclient.c | 3 +- src/rpc/virnetsshsession.c | 45 ++-- src/rpc/virnettlscontext.c | 6 +- src/security/security_dac.c | 3 +- src/storage/storage_backend_disk.c | 3 +- src/storage/storage_backend_fs.c | 3 +- src/storage/storage_backend_zfs.c | 3 +- src/storage/storage_driver.c | 21 +- src/storage/storage_util.c | 48 ++-- src/storage_file/storage_source.c | 3 +- .../storage_source_backingstore.c | 36 +-- src/test/test_driver.c | 39 ++-- src/util/vircgroupv2devices.c | 13 +- src/util/vircommand.c | 3 +- src/util/virfile.c | 3 +- src/util/virhostcpu.c | 3 +- src/util/virhostmem.c | 6 +- src/util/virjson.c | 3 +- src/util/virmdev.c | 3 +- src/util/virnetdev.c | 12 +- src/util/virnetdevbandwidth.c | 6 +- src/util/virnetdevopenvswitch.c | 6 +- src/util/virnetdevvportprofile.c | 6 +- src/util/virnetlink.c | 3 +- src/util/virnuma.c | 6 +- src/util/virpci.c | 3 +- src/util/virprocess.c | 9 +- src/util/virqemu.c | 3 +- src/util/virresctrl.c | 9 +- src/util/virthreadpool.c | 3 +- src/vbox/vbox_snapshot_conf.c | 6 +- src/vmware/vmware_conf.c | 9 +- src/vmware/vmware_driver.c | 6 +- src/vmx/vmx.c | 21 +- src/vz/vz_driver.c | 15 +- src/vz/vz_sdk.c | 135 ++++------- src/vz/vz_utils.c | 66 ++---- tools/virsh-domain-event.c | 15 +- tools/virsh-domain.c | 36 +-- tools/virsh-host.c | 9 +- tools/virsh-network.c | 6 +- tools/virsh-nodedev.c | 3 +- tools/virsh-pool.c | 3 +- tools/virsh.c | 9 +- tools/virt-admin.c | 21 +- tools/virt-host-validate-ch.c | 12 +- tools/virt-host-validate-qemu.c | 15 +- tools/vsh.c | 12 +- 115 files changed, 689 insertions(+), 1403 deletions(-) -- 2.41.0

Error messages are exempt from the 80 columns rule. Move them onto one line. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/bhyve/bhyve_command.c | 31 ++++++++++--------------------- src/bhyve/bhyve_domain.c | 3 +-- src/bhyve/bhyve_driver.c | 3 +-- 3 files changed, 12 insertions(+), 25 deletions(-) diff --git a/src/bhyve/bhyve_command.c b/src/bhyve/bhyve_command.c index 563651336e..82e7e96816 100644 --- a/src/bhyve/bhyve_command.c +++ b/src/bhyve/bhyve_command.c @@ -60,8 +60,7 @@ bhyveBuildNetArgStr(const virDomainDef *def, nic_model = g_strdup("e1000"); } else { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("NIC model 'e1000' is not supported " - "by given bhyve binary")); + _("NIC model 'e1000' is not supported by given bhyve binary")); return -1; } } else { @@ -190,8 +189,7 @@ bhyveBuildAHCIControllerArgStr(const virDomainDef *def, if ((disk->device == VIR_DOMAIN_DISK_DEVICE_CDROM) && (disk_source == NULL)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("cdrom device without source path " - "not supported")); + _("cdrom device without source path not supported")); return -1; } @@ -341,8 +339,7 @@ bhyveBuildControllerArgStr(const virDomainDef *def, case VIR_DOMAIN_CONTROLLER_TYPE_PCI: if (controller->model != VIR_DOMAIN_CONTROLLER_MODEL_PCI_ROOT) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("unsupported PCI controller model: " - "only PCI root supported")); + _("unsupported PCI controller model: only PCI root supported")); return -1; } break; @@ -391,8 +388,7 @@ bhyveBuildGraphicsArgStr(const virDomainDef *def, def->os.bootloader || !def->os.loader) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Graphics are only supported" - " when booting using UEFI")); + _("Graphics are only supported when booting using UEFI")); return -1; } @@ -465,8 +461,7 @@ bhyveBuildGraphicsArgStr(const virDomainDef *def, if (graphics->data.vnc.auth.passwd) { if (!(bhyveDriverGetBhyveCaps(driver) & BHYVE_CAP_VNC_PASSWORD)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("VNC Password authentication not supported " - "by bhyve")); + _("VNC Password authentication not supported by bhyve")); return -1; } @@ -510,8 +505,7 @@ bhyveBuildSoundArgStr(const virDomainDef *def G_GNUC_UNUSED, /* Currently, bhyve only supports "hda" sound devices, so if it's not supported, sound devices are not supported at all */ virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Sound devices emulation is not supported " - "by given bhyve binary")); + _("Sound devices emulation is not supported by given bhyve binary")); return -1; } @@ -667,9 +661,7 @@ virBhyveProcessBuildBhyveCmd(struct _bhyveConn *driver, virDomainDef *def, } if (nvcpus != def->cpu->sockets * def->cpu->cores * def->cpu->threads) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Invalid CPU topology: total number of vCPUs " - "must equal the product of sockets, cores, " - "and threads")); + _("Invalid CPU topology: total number of vCPUs must equal the product of sockets, cores, and threads")); return NULL; } @@ -681,8 +673,7 @@ virBhyveProcessBuildBhyveCmd(struct _bhyveConn *driver, virDomainDef *def, def->cpu->threads); } else { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Installed bhyve binary does not support " - "defining CPU topology")); + _("Installed bhyve binary does not support defining CPU topology")); return NULL; } } else { @@ -716,8 +707,7 @@ virBhyveProcessBuildBhyveCmd(struct _bhyveConn *driver, virDomainDef *def, virCommandAddArg(cmd, "-u"); } else { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Installed bhyve binary does not support " - "UTC clock")); + _("Installed bhyve binary does not support UTC clock")); return NULL; } break; @@ -751,8 +741,7 @@ virBhyveProcessBuildBhyveCmd(struct _bhyveConn *driver, virDomainDef *def, virCommandAddArgFormat(cmd, "bootrom,%s", def->os.loader->path); } else { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Installed bhyve binary does not support " - "UEFI loader")); + _("Installed bhyve binary does not support UEFI loader")); return NULL; } } diff --git a/src/bhyve/bhyve_domain.c b/src/bhyve/bhyve_domain.c index a8b1f97790..c47ad392a0 100644 --- a/src/bhyve/bhyve_domain.c +++ b/src/bhyve/bhyve_domain.c @@ -174,8 +174,7 @@ bhyveDomainDeviceDefPostParse(virDomainDeviceDef *dev, cont->model == VIR_DOMAIN_CONTROLLER_MODEL_PCIE_ROOT) && cont->idx != 0) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("pci-root and pcie-root controllers " - "should have index 0")); + _("pci-root and pcie-root controllers should have index 0")); return -1; } } diff --git a/src/bhyve/bhyve_driver.c b/src/bhyve/bhyve_driver.c index 10ef2f2f41..4203b13f94 100644 --- a/src/bhyve/bhyve_driver.c +++ b/src/bhyve/bhyve_driver.c @@ -694,8 +694,7 @@ bhyveConnectDomainXMLToNative(virConnectPtr conn, if ((bhyveDriverGetBhyveCaps(privconn) & BHYVE_CAP_LPC_BOOTROM) == 0) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Installed bhyve binary does not support " - "bootrom")); + _("Installed bhyve binary does not support bootrom")); return NULL; } } else { -- 2.41.0

Error messages are exempt from the 80 columns rule. Move them onto one line. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/ch/ch_driver.c | 3 +-- src/ch/ch_monitor.c | 3 +-- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/src/ch/ch_driver.c b/src/ch/ch_driver.c index 45cdbfd37c..b62645a8c8 100644 --- a/src/ch/ch_driver.c +++ b/src/ch/ch_driver.c @@ -1379,8 +1379,7 @@ chDomainPinEmulator(virDomainPtr dom, if (virDomainCgroupSetupCpusetCpus(cgroup_emulator, pcpumap) < 0) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("failed to set cpuset.cpus in cgroup" - " for emulator threads")); + _("failed to set cpuset.cpus in cgroup for emulator threads")); goto endjob; } } diff --git a/src/ch/ch_monitor.c b/src/ch/ch_monitor.c index a4b921931b..4f32b1ee4c 100644 --- a/src/ch/ch_monitor.c +++ b/src/ch/ch_monitor.c @@ -637,8 +637,7 @@ virCHMonitorCurlPerform(CURL *handle) if (responseCode < 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("curl_easy_getinfo(CURLINFO_RESPONSE_CODE) returned a " - "negative response code")); + _("curl_easy_getinfo(CURLINFO_RESPONSE_CODE) returned a negative response code")); return -1; } -- 2.41.0

Error messages are exempt from the 80 columns rule. Move them onto one line. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/conf/cpu_conf.c | 9 +- src/conf/domain_addr.c | 3 +- src/conf/domain_conf.c | 138 +++++++++++-------------------- src/conf/domain_validate.c | 54 ++++-------- src/conf/netdev_bandwidth_conf.c | 3 +- src/conf/netdev_vlan_conf.c | 6 +- src/conf/network_conf.c | 27 ++---- src/conf/node_device_conf.c | 3 +- src/conf/node_device_util.c | 3 +- src/conf/numa_conf.c | 25 ++---- src/conf/nwfilter_params.c | 6 +- src/conf/snapshot_conf.c | 3 +- src/conf/storage_adapter_conf.c | 18 ++-- src/conf/virdomainjob.c | 3 +- src/conf/virnetworkobj.c | 3 +- 15 files changed, 101 insertions(+), 203 deletions(-) diff --git a/src/conf/cpu_conf.c b/src/conf/cpu_conf.c index 98adb0e5d5..7abe489733 100644 --- a/src/conf/cpu_conf.c +++ b/src/conf/cpu_conf.c @@ -394,8 +394,7 @@ virCPUDefParseXML(xmlXPathContextPtr ctxt, if (virXPathBoolean("boolean(./arch)", ctxt)) { if (virXPathBoolean("boolean(./@match)", ctxt)) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("'arch' element cannot be used inside 'cpu'" - " element with 'match' attribute'")); + _("'arch' element cannot be used inside 'cpu' element with 'match' attribute'")); return -1; } def->type = VIR_CPU_TYPE_HOST; @@ -436,8 +435,7 @@ virCPUDefParseXML(xmlXPathContextPtr ctxt, def->mode != VIR_CPU_MODE_HOST_PASSTHROUGH && def->mode != VIR_CPU_MODE_MAXIMUM) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Attribute migratable is only allowed for " - "'host-passthrough' / 'maximum' CPU mode")); + _("Attribute migratable is only allowed for 'host-passthrough' / 'maximum' CPU mode")); return -1; } @@ -593,8 +591,7 @@ virCPUDefParseXML(xmlXPathContextPtr ctxt, if (n > 0) { if (!def->model && def->mode == VIR_CPU_MODE_CUSTOM) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("Non-empty feature list specified without " - "CPU model")); + _("Non-empty feature list specified without CPU model")); return -1; } diff --git a/src/conf/domain_addr.c b/src/conf/domain_addr.c index 23c06ff6a4..a53ff6df6c 100644 --- a/src/conf/domain_addr.c +++ b/src/conf/domain_addr.c @@ -905,8 +905,7 @@ virDomainPCIAddressEnsureAddr(virDomainPCIAddressSet *addrs, */ if (dev->addr.pci.function != 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Only PCI device addresses with function=0" - " are supported")); + _("Only PCI device addresses with function=0 are supported")); return -1; } diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index 69934026ef..2d585e7470 100644 --- a/src/conf/domain_conf.c +++ b/src/conf/domain_conf.c @@ -2152,8 +2152,7 @@ virDomainDefSetVcpus(virDomainDef *def, if (vcpus > def->maxvcpus) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("maximum vCPU count must not be less than current " - "vCPU count")); + _("maximum vCPU count must not be less than current vCPU count")); return -1; } @@ -4348,8 +4347,7 @@ virDomainObjUpdateModificationImpact(virDomainObj *vm, if (!vm->persistent && (*flags & VIR_DOMAIN_AFFECT_CONFIG)) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("transient domains do not have any " - "persistent config")); + _("transient domains do not have any persistent config")); return -1; } @@ -4429,9 +4427,7 @@ virDomainObjGetOneDefState(virDomainObj *vm, if (flags & VIR_DOMAIN_AFFECT_LIVE && flags & VIR_DOMAIN_AFFECT_CONFIG) { virReportInvalidArg(flags, "%s", - _("Flags 'VIR_DOMAIN_AFFECT_LIVE' and " - "'VIR_DOMAIN_AFFECT_CONFIG' are mutually " - "exclusive")); + _("Flags 'VIR_DOMAIN_AFFECT_LIVE' and 'VIR_DOMAIN_AFFECT_CONFIG' are mutually exclusive")); return NULL; } @@ -6027,8 +6023,7 @@ virDomainHostdevSubsysSCSIiSCSIDefParseXML(xmlNodePtr sourcenode, } if (iscsisrc->src->nhosts > 1) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("only one source host address may be specified " - "for the iSCSI hostdev")); + _("only one source host address may be specified for the iSCSI hostdev")); return -1; } @@ -6239,8 +6234,7 @@ virDomainHostdevDefParseXMLSubsys(xmlNodePtr node, if (def->source.subsys.type != VIR_DOMAIN_HOSTDEV_SUBSYS_TYPE_USB && virXPathBoolean("boolean(./source/@startupPolicy)", ctxt)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Setting startupPolicy is only allowed for USB" - " devices")); + _("Setting startupPolicy is only allowed for USB devices")); return -1; } @@ -6885,8 +6879,7 @@ virSecurityLabelDefsParseXML(virDomainDef *def, for (; n; n--) { if (def->seclabels[n - 1]->model == NULL) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("missing security model " - "when using multiple labels")); + _("missing security model when using multiple labels")); goto error; } } @@ -7075,8 +7068,7 @@ virDomainDiskSourcePoolDefParse(xmlNodePtr node, if (!source->pool || !source->volume) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("'pool' and 'volume' must be specified together " - "for 'pool' type source")); + _("'pool' and 'volume' must be specified together for 'pool' type source")); goto cleanup; } @@ -7709,8 +7701,7 @@ virDomainDiskDefMirrorParse(virDomainDiskDef *def, } else { if (def->mirrorJob != VIR_DOMAIN_BLOCK_JOB_TYPE_COPY) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("mirror without type only supported " - "by copy job")); + _("mirror without type only supported by copy job")); return -1; } mirrorFormat = virXMLPropString(cur, "format"); @@ -8925,8 +8916,7 @@ virDomainActualNetDefParseXML(xmlNodePtr node, if (!brname && actual->type == VIR_DOMAIN_NET_TYPE_BRIDGE) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Missing <source> element with bridge name in " - "interface's <actual> element")); + _("Missing <source> element with bridge name in interface's <actual> element")); goto error; } actual->data.bridge.brname = brname; @@ -9878,8 +9868,7 @@ virDomainChrDefParseTargetXML(virDomainChrDef *def, if (addrStr == NULL) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("guestfwd channel does not " - "define a target address")); + _("guestfwd channel does not define a target address")); return -1; } @@ -9887,9 +9876,8 @@ virDomainChrDefParseTargetXML(virDomainChrDef *def, return -1; if (def->target.addr->data.stor.ss_family != AF_INET) { - virReportError(VIR_ERR_CONFIG_UNSUPPORTED, - "%s", _("guestfwd channel only supports " - "IPv4 addresses")); + virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", + _("guestfwd channel only supports IPv4 addresses")); return -1; } @@ -10133,14 +10121,12 @@ virDomainChrSourceDefParseXML(virDomainChrSourceDef *def, * user can specify two source elements. */ if (nsources > 1 && def->type != VIR_DOMAIN_CHR_TYPE_UDP) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("only one source element is allowed for " - "character device")); + _("only one source element is allowed for character device")); goto error; } if (nsources > 2) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("only two source elements are allowed for " - "character device")); + _("only two source elements are allowed for character device")); goto error; } @@ -10225,8 +10211,7 @@ virDomainChrSourceDefParseXML(virDomainChrSourceDef *def, goto error; } else if (nlogs > 1) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("only one log element is allowed for " - "character device")); + _("only one log element is allowed for character device")); goto error; } @@ -10238,8 +10223,7 @@ virDomainChrSourceDefParseXML(virDomainChrSourceDef *def, goto error; } else if (nprotocols > 1) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("only one protocol element is allowed for " - "character device")); + _("only one protocol element is allowed for character device")); goto error; } @@ -10393,8 +10377,7 @@ virDomainChrDefParseXML(virDomainXMLOption *xmlopt, if (def->source->type == VIR_DOMAIN_CHR_TYPE_SPICEVMC) { if (def->targetType != VIR_DOMAIN_CHR_CHANNEL_TARGET_TYPE_VIRTIO) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("spicevmc device type only supports " - "virtio")); + _("spicevmc device type only supports virtio")); goto error; } else { def->source->data.spicevmc = VIR_DOMAIN_CHR_SPICEVMC_VDAGENT; @@ -10447,8 +10430,7 @@ virDomainSmartcardDefParseXML(virDomainXMLOption *xmlopt, n = virXPathNodeSet("./certificate", ctxt, &certificates); if (n != VIR_DOMAIN_SMARTCARD_NUM_CERTIFICATES) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("host-certificates mode needs " - "exactly three certificates")); + _("host-certificates mode needs exactly three certificates")); return NULL; } @@ -10476,8 +10458,7 @@ virDomainSmartcardDefParseXML(virDomainXMLOption *xmlopt, type = virXMLPropString(node, "type"); if (type == NULL) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("passthrough mode requires a character " - "device type attribute")); + _("passthrough mode requires a character device type attribute")); return NULL; } @@ -11065,8 +11046,7 @@ virDomainGraphicsListenDefParseXML(virDomainGraphicsListenDef *def, if (network && network[0]) { if (def->type != VIR_DOMAIN_GRAPHICS_LISTEN_TYPE_NETWORK) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("'network' attribute is valid only for listen " - "type 'network'")); + _("'network' attribute is valid only for listen type 'network'")); goto error; } def->network = g_steal_pointer(&network); @@ -11075,8 +11055,7 @@ virDomainGraphicsListenDefParseXML(virDomainGraphicsListenDef *def, if (socketPath && socketPath[0]) { if (def->type != VIR_DOMAIN_GRAPHICS_LISTEN_TYPE_SOCKET) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("'socket' attribute is valid only for listen " - "type 'socket'")); + _("'socket' attribute is valid only for listen type 'socket'")); goto error; } def->socket = g_steal_pointer(&socketPath); @@ -12681,8 +12660,7 @@ virSysinfoParseFWCfgDef(virSysinfoDef *def, if (!value && !file) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("Firmware entry must have either value or " - "'file' attribute")); + _("Firmware entry must have either value or 'file' attribute")); return -1; } @@ -13472,8 +13450,7 @@ virDomainSEVDefParseXML(virDomainSEVDef *def, def->haveReducedPhysBits = true; } else if (rc == -2) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("Invalid format for launch security " - "reduced-phys-bits")); + _("Invalid format for launch security reduced-phys-bits")); return -1; } @@ -15440,8 +15417,7 @@ virDomainMemoryInsert(virDomainDef *def, if (mem->info.type != VIR_DOMAIN_DEVICE_ADDRESS_TYPE_NONE && virDomainDefHasDeviceAddress(def, &mem->info)) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("Domain already contains a device with the same " - "address")); + _("Domain already contains a device with the same address")); return -1; } @@ -18636,16 +18612,14 @@ virDomainDefControllersParse(virDomainDef *def, if (controller->model == VIR_DOMAIN_CONTROLLER_MODEL_USB_NONE) { if (usb_other || *usb_none) { virReportError(VIR_ERR_XML_DETAIL, "%s", - _("Can't add another USB controller: " - "USB is disabled for this domain")); + _("Can't add another USB controller: USB is disabled for this domain")); return -1; } *usb_none = true; } else { if (*usb_none) { virReportError(VIR_ERR_XML_DETAIL, "%s", - _("Can't add another USB controller: " - "USB is disabled for this domain")); + _("Can't add another USB controller: USB is disabled for this domain")); return -1; } usb_other = true; @@ -18723,8 +18697,7 @@ virDomainDefParseXML(xmlXPathContextPtr ctxt, if (virDomainNumaGetCPUCountTotal(def->numa) > virDomainDefGetVcpusMax(def)) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Number of CPUs in <numa> exceeds the" - " <vcpu> count")); + _("Number of CPUs in <numa> exceeds the <vcpu> count")); return NULL; } @@ -18978,8 +18951,7 @@ virDomainDefParseXML(xmlXPathContextPtr ctxt, if (input->bus == VIR_DOMAIN_INPUT_BUS_USB && usb_none) { virDomainInputDefFree(input); virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Can't add USB input device. " - "USB bus is disabled")); + _("Can't add USB input device. USB bus is disabled")); return NULL; } @@ -19081,8 +19053,7 @@ virDomainDefParseXML(xmlXPathContextPtr ctxt, if (hostdev->source.subsys.type == VIR_DOMAIN_HOSTDEV_SUBSYS_TYPE_USB && usb_none) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Can't add host USB device: " - "USB is disabled in this host")); + _("Can't add host USB device: USB is disabled in this host")); virDomainHostdevDefFree(hostdev); return NULL; } @@ -19173,8 +19144,7 @@ virDomainDefParseXML(xmlXPathContextPtr ctxt, if (n > 2) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("a maximum of two TPM devices is supported, one of " - "them being a TPM Proxy device")); + _("a maximum of two TPM devices is supported, one of them being a TPM Proxy device")); return NULL; } @@ -19222,8 +19192,7 @@ virDomainDefParseXML(xmlXPathContextPtr ctxt, if (hub->type == VIR_DOMAIN_HUB_TYPE_USB && usb_none) { virDomainHubDefFree(hub); virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Can't add USB hub: " - "USB is disabled for this domain")); + _("Can't add USB hub: USB is disabled for this domain")); return NULL; } @@ -20347,8 +20316,7 @@ virDomainChannelDefCheckABIStability(virDomainChrDef *src, dst->source->type == VIR_DOMAIN_CHR_TYPE_SPICEVMC) && !src->target.name) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Changing device type to/from spicevmc would" - " change default target channel name")); + _("Changing device type to/from spicevmc would change default target channel name")); return false; } break; @@ -20926,8 +20894,7 @@ virDomainShmemDefCheckABIStability(virDomainShmemDef *src, if (src->server.enabled != dst->server.enabled) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Target shared memory server usage doesn't match " - "source")); + _("Target shared memory server usage doesn't match source")); return false; } @@ -20935,8 +20902,7 @@ virDomainShmemDefCheckABIStability(virDomainShmemDef *src, src->msi.enabled != dst->msi.enabled || src->msi.ioeventfd != dst->msi.ioeventfd) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Target shared memory MSI configuration doesn't match " - "source")); + _("Target shared memory MSI configuration doesn't match source")); return false; } @@ -21074,15 +21040,13 @@ virDomainMemoryDefCheckABIStability(virDomainMemoryDef *src, if (src->source.nvdimm.pmem != dst->source.nvdimm.pmem) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Target NVDIMM pmem flag doesn't match " - "source NVDIMM pmem flag")); + _("Target NVDIMM pmem flag doesn't match source NVDIMM pmem flag")); return false; } if (src->target.nvdimm.readonly != dst->target.nvdimm.readonly) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Target NVDIMM readonly flag doesn't match " - "source NVDIMM readonly flag")); + _("Target NVDIMM readonly flag doesn't match source NVDIMM readonly flag")); return false; } @@ -21655,8 +21619,7 @@ virDomainDefCheckABIStabilityFlags(virDomainDef *src, if (!!src->iommu != !!dst->iommu) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Target domain IOMMU device count " - "does not match source")); + _("Target domain IOMMU device count does not match source")); goto error; } @@ -21666,8 +21629,7 @@ virDomainDefCheckABIStabilityFlags(virDomainDef *src, if (!!src->vsock != !!dst->vsock) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Target domain vsock device count " - "does not match source")); + _("Target domain vsock device count does not match source")); goto error; } @@ -28155,16 +28117,14 @@ virDomainDefCompatibleDevice(virDomainDef *def, def->os.type != VIR_DOMAIN_OSTYPE_EXE && virDomainDeviceIsUSB(dev)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Device configuration is not compatible: " - "Domain has no USB bus support")); + _("Device configuration is not compatible: Domain has no USB bus support")); return -1; } if (data.newInfo && data.newInfo->bootIndex > 0) { if (def->os.nBootDevs > 0) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("per-device boot elements cannot be used" - " together with os/boot elements")); + _("per-device boot elements cannot be used together with os/boot elements")); return -1; } if (virDomainDeviceInfoIterate(def, @@ -28178,8 +28138,7 @@ virDomainDefCompatibleDevice(virDomainDef *def, if (!virDomainDefHasMemoryHotplug(def)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("cannot use/hotplug a memory device when domain " - "'maxMemory' is not defined")); + _("cannot use/hotplug a memory device when domain 'maxMemory' is not defined")); return -1; } @@ -29586,23 +29545,20 @@ virDomainDefGetShortName(const virDomainDef *def) if (len == (size_t) -1) { virReportSystemError(errno, "%s", - _("Cannot convert domain name to " - "wide character string")); + _("Cannot convert domain name to wide character string")); return NULL; } if (mbstowcs(wshortname, def->name, VIR_DOMAIN_SHORT_NAME_MAX) == (size_t) -1) { virReportSystemError(errno, "%s", - _("Cannot convert domain name to " - "wide character string")); + _("Cannot convert domain name to wide character string")); return NULL; } len = wcstombs(NULL, wshortname, 0); if (len == (size_t) -1) { virReportSystemError(errno, "%s", - _("Cannot convert wide character string " - "back to multi-byte domain name")); + _("Cannot convert wide character string back to multi-byte domain name")); return NULL; } @@ -29610,8 +29566,7 @@ virDomainDefGetShortName(const virDomainDef *def) if (wcstombs(shortname, wshortname, len) == (size_t) -1) { virReportSystemError(errno, "%s", - _("Cannot convert wide character string " - "back to multi-byte domain name")); + _("Cannot convert wide character string back to multi-byte domain name")); return NULL; } @@ -30462,8 +30417,7 @@ virDomainStorageSourceTranslateSourcePool(virStorageSource *src, if (src->srcpool->mode && pooldef->type != VIR_STORAGE_POOL_ISCSI) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("disk source mode is only valid when " - "storage pool is of iscsi type")); + _("disk source mode is only valid when storage pool is of iscsi type")); return -1; } diff --git a/src/conf/domain_validate.c b/src/conf/domain_validate.c index b286990b19..08dc8f7578 100644 --- a/src/conf/domain_validate.c +++ b/src/conf/domain_validate.c @@ -38,16 +38,14 @@ virDomainDefBootValidate(const virDomainDef *def) { if (def->os.bm_timeout_set && def->os.bm_timeout > 65535) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("invalid value for boot menu timeout, " - "must be in range [0,65535]")); + _("invalid value for boot menu timeout, must be in range [0,65535]")); return -1; } if (def->os.bios.rt_set && (def->os.bios.rt_delay < -1 || def->os.bios.rt_delay > 65535)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("invalid value for rebootTimeout, " - "must be in range [-1,65535]")); + _("invalid value for rebootTimeout, must be in range [-1,65535]")); return -1; } @@ -118,20 +116,17 @@ virDomainCheckVirtioOptionsAreAbsent(virDomainVirtioOptions *virtio) if (virtio->iommu != VIR_TRISTATE_SWITCH_ABSENT) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("iommu driver option is only supported " - "for virtio devices")); + _("iommu driver option is only supported for virtio devices")); return -1; } if (virtio->ats != VIR_TRISTATE_SWITCH_ABSENT) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("ats driver option is only supported " - "for virtio devices")); + _("ats driver option is only supported for virtio devices")); return -1; } if (virtio->packed != VIR_TRISTATE_SWITCH_ABSENT) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("packed driver option is only supported " - "for virtio devices")); + _("packed driver option is only supported for virtio devices")); return -1; } @@ -163,8 +158,7 @@ virDomainVideoDefValidate(const virDomainVideoDef *video, if (def->videos[i]->type == VIR_DOMAIN_VIDEO_TYPE_NONE && def->nvideos > 1) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("a 'none' video type must be the only video device " - "defined for the domain")); + _("a 'none' video type must be the only video device defined for the domain")); return -1; } } @@ -303,8 +297,7 @@ virSecurityDeviceLabelDefValidate(virSecurityDeviceLabelDef **seclabels, if (!vmSeclabels[j]->relabel) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("label overrides require relabeling to be " - "enabled at the domain level")); + _("label overrides require relabeling to be enabled at the domain level")); return -1; } } @@ -542,8 +535,7 @@ virDomainDiskDefValidateSourceChainOne(const virStorageSource *src) encryption->encinfo.cipher_name) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("supplying <cipher> for domain disk definition " - "is unnecessary")); + _("supplying <cipher> for domain disk definition is unnecessary")); return -1; } } @@ -553,15 +545,13 @@ virDomainDiskDefValidateSourceChainOne(const virStorageSource *src) src->protocol != VIR_STORAGE_NET_PROTOCOL_RBD) { if (src->snapshot) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("<snapshot> element is currently supported " - "only with 'rbd' disks")); + _("<snapshot> element is currently supported only with 'rbd' disks")); return -1; } if (src->configFile) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("<config> element is currently supported " - "only with 'rbd' disks")); + _("<config> element is currently supported only with 'rbd' disks")); return -1; } } @@ -997,8 +987,7 @@ virDomainChrSourceDefValidate(const virDomainChrSourceDef *src_def, if ((src_def->data.nmdm.master && !src_def->data.nmdm.slave) || (!src_def->data.nmdm.master && src_def->data.nmdm.slave)) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Should define both master and slave " - "path attributes for nmdm device")); + _("Should define both master and slave path attributes for nmdm device")); return -1; } @@ -1081,8 +1070,7 @@ virDomainRedirdevDefValidate(const virDomainDef *def, if (redirdev->bus == VIR_DOMAIN_REDIRDEV_BUS_USB && !virDomainDefHasUSB(def)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("cannot add redirected USB device: " - "USB is disabled for this domain")); + _("cannot add redirected USB device: USB is disabled for this domain")); return -1; } @@ -1640,8 +1628,7 @@ virDomainDefOSValidate(const virDomainDef *def, } else { if (def->os.firmwareFeatures) { virReportError(VIR_ERR_XML_DETAIL, "%s", - _("cannot use feature-based firmware autoselection " - "when firmware autoselection is disabled")); + _("cannot use feature-based firmware autoselection when firmware autoselection is disabled")); return -1; } @@ -1741,8 +1728,7 @@ virDomainDefIOMMUValidate(const virDomainDef *def) if (def->iommu->intremap == VIR_TRISTATE_SWITCH_ON && def->features[VIR_DOMAIN_FEATURE_IOAPIC] != VIR_DOMAIN_IOAPIC_QEMU) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("IOMMU interrupt remapping requires split I/O APIC " - "(ioapic driver='qemu')")); + _("IOMMU interrupt remapping requires split I/O APIC (ioapic driver='qemu')")); return -1; } @@ -2041,8 +2027,7 @@ virDomainNetDefValidate(const virDomainNetDef *net) if ((net->hostIP.nroutes || net->hostIP.nips) && net->type != VIR_DOMAIN_NET_TYPE_ETHERNET) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, - _("Invalid attempt to set network interface host-side IP route and/or address info on interface of type '%1$s'. " - "This is only supported on interfaces of type 'ethernet'"), + _("Invalid attempt to set network interface host-side IP route and/or address info on interface of type '%1$s'. This is only supported on interfaces of type 'ethernet'"), virDomainNetTypeToString(net->type)); return -1; } @@ -2168,8 +2153,7 @@ virDomainHostdevDefValidate(const virDomainHostdevDef *hostdev) hostdev->info->type != VIR_DOMAIN_DEVICE_ADDRESS_TYPE_UNASSIGNED && hostdev->info->type != VIR_DOMAIN_DEVICE_ADDRESS_TYPE_PCI) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("PCI host devices must use 'pci' or " - "'unassigned' address type")); + _("PCI host devices must use 'pci' or 'unassigned' address type")); return -1; } break; @@ -2177,8 +2161,7 @@ virDomainHostdevDefValidate(const virDomainHostdevDef *hostdev) if (hostdev->info->type != VIR_DOMAIN_DEVICE_ADDRESS_TYPE_NONE && hostdev->info->type != VIR_DOMAIN_DEVICE_ADDRESS_TYPE_DRIVE) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("SCSI host device must use 'drive' " - "address type")); + _("SCSI host device must use 'drive' address type")); return -1; } if (hostdev->source.subsys.u.scsi.sgio == VIR_DOMAIN_DEVICE_SGIO_UNFILTERED) { @@ -2192,8 +2175,7 @@ virDomainHostdevDefValidate(const virDomainHostdevDef *hostdev) hostdev->info->type != VIR_DOMAIN_DEVICE_ADDRESS_TYPE_PCI && hostdev->info->type != VIR_DOMAIN_DEVICE_ADDRESS_TYPE_CCW) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("SCSI_host host device must use 'pci' " - "or 'ccw' address type")); + _("SCSI_host host device must use 'pci' or 'ccw' address type")); return -1; } break; diff --git a/src/conf/netdev_bandwidth_conf.c b/src/conf/netdev_bandwidth_conf.c index 38b7cc10fd..cdf289270a 100644 --- a/src/conf/netdev_bandwidth_conf.c +++ b/src/conf/netdev_bandwidth_conf.c @@ -105,8 +105,7 @@ virNetDevBandwidthParse(virNetDevBandwidth **bandwidth, if (rc == 1) { if (!class_id) { virReportError(VIR_ERR_XML_DETAIL, "%s", - _("classID attribute not supported on <bandwidth> " - "in this usage context")); + _("classID attribute not supported on <bandwidth> in this usage context")); return -1; } diff --git a/src/conf/netdev_vlan_conf.c b/src/conf/netdev_vlan_conf.c index 96ac7f3428..1ac66aec54 100644 --- a/src/conf/netdev_vlan_conf.c +++ b/src/conf/netdev_vlan_conf.c @@ -47,8 +47,7 @@ virNetDevVlanParse(xmlNodePtr node, xmlXPathContextPtr ctxt, virNetDevVlan *def) if (nTags == 0) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("missing tag id - each <vlan> must have " - "at least one <tag id='n'/> subelement")); + _("missing tag id - each <vlan> must have at least one <tag id='n'/> subelement")); goto cleanup; } @@ -106,8 +105,7 @@ virNetDevVlanParse(xmlNodePtr node, xmlXPathContextPtr ctxt, virNetDevVlan *def) } if (def->nativeMode != 0) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("invalid configuration in <vlan> - \"trunk='no'\" is " - "not allowed with a native vlan id")); + _("invalid configuration in <vlan> - \"trunk='no'\" is not allowed with a native vlan id")); goto cleanup; } /* allow (but discard) "trunk='no' if there is a single tag */ diff --git a/src/conf/network_conf.c b/src/conf/network_conf.c index 3e137cb562..83214e2087 100644 --- a/src/conf/network_conf.c +++ b/src/conf/network_conf.c @@ -430,8 +430,7 @@ virNetworkDHCPLeaseTimeDefParseXML(virNetworkDHCPLeaseTimeDef **lease, if ((unit == VIR_NETWORK_DHCP_LEASETIME_UNIT_SECONDS && expiry < 120) || (unit == VIR_NETWORK_DHCP_LEASETIME_UNIT_MINUTES && expiry < 2)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("The minimum lease time should be greater " - "than 2 minutes")); + _("The minimum lease time should be greater than 2 minutes")); return -1; } } @@ -920,8 +919,7 @@ virNetworkDNSDefParseXML(const char *networkName, def->forwarders[i].domain = virXMLPropString(fwdNodes[i], "domain"); if (!(addr || def->forwarders[i].domain)) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("Invalid forwarder element, must contain " - "at least one of addr or domain")); + _("Invalid forwarder element, must contain at least one of addr or domain")); return -1; } def->nfwds++; @@ -2766,8 +2764,7 @@ virNetworkDefUpdateIPDHCPHost(virNetworkDef *def, VIR_SOCKET_ADDR_FAMILY(&ipdef->address) != VIR_SOCKET_ADDR_FAMILY(&host.ip)) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("the address family of a host entry IP must match " - "the address family of the dhcp element's parent")); + _("the address family of a host entry IP must match the address family of the dhcp element's parent")); goto cleanup; } @@ -2892,8 +2889,7 @@ virNetworkDefUpdateIPDHCPRange(virNetworkDef *def, if (command == VIR_NETWORK_UPDATE_COMMAND_MODIFY) { virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("dhcp ranges cannot be modified, " - "only added or deleted")); + _("dhcp ranges cannot be modified, only added or deleted")); return -1; } @@ -2903,8 +2899,7 @@ virNetworkDefUpdateIPDHCPRange(virNetworkDef *def, if (VIR_SOCKET_ADDR_FAMILY(&ipdef->address) != VIR_SOCKET_ADDR_FAMILY(&range.addr.start)) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("the address family of a dhcp range must match " - "the address family of the dhcp element's parent")); + _("the address family of a dhcp range must match the address family of the dhcp element's parent")); return -1; } @@ -2993,8 +2988,7 @@ virNetworkDefUpdateForwardInterface(virNetworkDef *def, if (command == VIR_NETWORK_UPDATE_COMMAND_MODIFY) { virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("forward interface entries cannot be modified, " - "only added or deleted")); + _("forward interface entries cannot be modified, only added or deleted")); goto cleanup; } @@ -3183,8 +3177,7 @@ virNetworkDefUpdateDNSHost(virNetworkDef *def, if (command == VIR_NETWORK_UPDATE_COMMAND_MODIFY) { virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("DNS HOST records cannot be modified, " - "only added or deleted")); + _("DNS HOST records cannot be modified, only added or deleted")); goto cleanup; } @@ -3280,8 +3273,7 @@ virNetworkDefUpdateDNSSrv(virNetworkDef *def, if (command == VIR_NETWORK_UPDATE_COMMAND_MODIFY) { virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("DNS SRV records cannot be modified, " - "only added or deleted")); + _("DNS SRV records cannot be modified, only added or deleted")); goto cleanup; } @@ -3362,8 +3354,7 @@ virNetworkDefUpdateDNSTxt(virNetworkDef *def, if (command == VIR_NETWORK_UPDATE_COMMAND_MODIFY) { virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("DNS TXT records cannot be modified, " - "only added or deleted")); + _("DNS TXT records cannot be modified, only added or deleted")); goto cleanup; } diff --git a/src/conf/node_device_conf.c b/src/conf/node_device_conf.c index 81c9f2a9c8..f722ab37c6 100644 --- a/src/conf/node_device_conf.c +++ b/src/conf/node_device_conf.c @@ -930,8 +930,7 @@ virNodeDevCapMdevTypesParseXML(xmlXPathContextPtr ctxt, if (!(type->id = virXPathString("string(./@id[1])", ctxt))) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("missing 'id' attribute for mediated device's " - "<type> element")); + _("missing 'id' attribute for mediated device's <type> element")); goto cleanup; } diff --git a/src/conf/node_device_util.c b/src/conf/node_device_util.c index cfe1b1077e..8f2ffd799f 100644 --- a/src/conf/node_device_util.c +++ b/src/conf/node_device_util.c @@ -103,8 +103,7 @@ virNodeDeviceCreateVport(virStorageAdapterFCHost *fchost) } else { if (!(parent_hoststr = virVHBAFindVportHost(NULL))) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("'parent' for vHBA not specified, and " - "cannot find one on this host")); + _("'parent' for vHBA not specified, and cannot find one on this host")); return NULL; } skip_capable_check = true; diff --git a/src/conf/numa_conf.c b/src/conf/numa_conf.c index 31b5ea58f6..bcd7838e00 100644 --- a/src/conf/numa_conf.c +++ b/src/conf/numa_conf.c @@ -147,15 +147,13 @@ virDomainNumatuneNodeParseXML(virDomainNuma *numa, if (numa->memory.specified && numa->memory.placement == VIR_DOMAIN_NUMATUNE_PLACEMENT_AUTO) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Per-node binding is not compatible with " - "automatic NUMA placement.")); + _("Per-node binding is not compatible with automatic NUMA placement.")); return -1; } if (!numa->nmem_nodes) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("Element 'memnode' is invalid without " - "any guest NUMA cells")); + _("Element 'memnode' is invalid without any guest NUMA cells")); return -1; } @@ -171,8 +169,7 @@ virDomainNumatuneNodeParseXML(virDomainNuma *numa, if (cellid >= numa->nmem_nodes) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("Argument 'cellid' in memnode element must " - "correspond to existing guest's NUMA cell")); + _("Argument 'cellid' in memnode element must correspond to existing guest's NUMA cell")); return -1; } @@ -194,8 +191,7 @@ virDomainNumatuneNodeParseXML(virDomainNuma *numa, tmp = virXMLPropString(cur_node, "nodeset"); if (!tmp) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("Missing required nodeset attribute " - "in memnode element")); + _("Missing required nodeset attribute in memnode element")); return -1; } if (virBitmapParse(tmp, &mem_node->nodeset, VIR_DOMAIN_CPUMASK_LEN) < 0) @@ -447,8 +443,7 @@ virDomainNumatuneMaybeGetNodeset(virDomainNuma *numatune, numatune->memory.placement == VIR_DOMAIN_NUMATUNE_PLACEMENT_AUTO && !auto_nodeset) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Advice from numad is needed in case of " - "automatic numa placement")); + _("Advice from numad is needed in case of automatic numa placement")); return -1; } @@ -533,8 +528,7 @@ virDomainNumatuneSet(virDomainNuma *numa, if (placement == VIR_DOMAIN_NUMATUNE_PLACEMENT_STATIC && !numa->memory.nodeset) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("nodeset for NUMA memory tuning must be set " - "if 'placement' is 'static'")); + _("nodeset for NUMA memory tuning must be set if 'placement' is 'static'")); return -1; } @@ -878,9 +872,7 @@ virDomainNumaDefParseXML(virDomainNuma *def, /* cells are in order of parsing or explicitly numbered */ if (cur_cell >= n) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("Exactly one 'cell' element per guest " - "NUMA cell allowed, non-contiguous ranges or " - "ranges not starting from 0 are not allowed")); + _("Exactly one 'cell' element per guest NUMA cell allowed, non-contiguous ranges or ranges not starting from 0 are not allowed")); return -1; } @@ -1385,8 +1377,7 @@ virDomainNumaSetNodeDistance(virDomainNuma *numa, if (!distances || cellid >= numa->mem_nodes[node].ndistances) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("Arguments under memnode element do not " - "correspond with existing guest's NUMA cell")); + _("Arguments under memnode element do not correspond with existing guest's NUMA cell")); return -1; } diff --git a/src/conf/nwfilter_params.c b/src/conf/nwfilter_params.c index 868baf7192..49d23936a3 100644 --- a/src/conf/nwfilter_params.c +++ b/src/conf/nwfilter_params.c @@ -362,10 +362,8 @@ virNWFilterVarCombIterAddVariable(virNWFilterVarCombIterEntry *cie, cie->curValue = minValue; } else { if (cie->maxValue != maxValue) { - virReportError(VIR_ERR_INTERNAL_ERROR, - _("Cardinality of list items must be " - "the same for processing them in " - "parallel")); + virReportError(VIR_ERR_INTERNAL_ERROR, "%s", + _("Cardinality of list items must be the same for processing them in parallel")); return -1; } } diff --git a/src/conf/snapshot_conf.c b/src/conf/snapshot_conf.c index 67cec34920..4b0555eb8c 100644 --- a/src/conf/snapshot_conf.c +++ b/src/conf/snapshot_conf.c @@ -355,8 +355,7 @@ virDomainSnapshotDefParse(xmlXPathContextPtr ctxt, def->memory != VIR_DOMAIN_SNAPSHOT_LOCATION_DEFAULT && def->memory != VIR_DOMAIN_SNAPSHOT_LOCATION_NO) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("memory state cannot be saved with offline or " - "disk-only snapshot")); + _("memory state cannot be saved with offline or disk-only snapshot")); return NULL; } diff --git a/src/conf/storage_adapter_conf.c b/src/conf/storage_adapter_conf.c index 2a8a1a3eb5..330f436597 100644 --- a/src/conf/storage_adapter_conf.c +++ b/src/conf/storage_adapter_conf.c @@ -100,8 +100,7 @@ virStorageAdapterParseXMLSCSIHost(xmlNodePtr node, &scsi_host->unique_id) < 0) || (scsi_host->unique_id < 0)) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("Missing or invalid scsi adapter " - "'unique_id' value")); + _("Missing or invalid scsi adapter 'unique_id' value")); return -1; } } @@ -140,15 +139,13 @@ virStorageAdapterParseXMLLegacy(xmlNodePtr node, VIR_FREE(wwpn); VIR_FREE(parent); virReportError(VIR_ERR_XML_ERROR, "%s", - _("Use of 'wwnn', 'wwpn', and 'parent' attributes " - "requires use of the adapter 'type'")); + _("Use of 'wwnn', 'wwpn', and 'parent' attributes requires use of the adapter 'type'")); return -1; } if (virXPathNode("./parentaddr", ctxt)) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("Use of 'parentaddr' element requires use " - "of the adapter 'type'")); + _("Use of 'parentaddr' element requires use of the adapter 'type'")); return -1; } @@ -198,8 +195,7 @@ virStorageAdapterValidateFCHost(virStorageAdapterFCHost *fchost) { if (!fchost->wwnn || !fchost->wwpn) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("'wwnn' and 'wwpn' must be specified for adapter " - "type 'fchost'")); + _("'wwnn' and 'wwpn' must be specified for adapter type 'fchost'")); return -1; } @@ -238,15 +234,13 @@ virStorageAdapterValidateSCSIHost(virStorageAdapterSCSIHost *scsi_host) { if (!scsi_host->name && !scsi_host->has_parent) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("Either 'name' or 'parent' must be specified " - "for the 'scsi_host' adapter")); + _("Either 'name' or 'parent' must be specified for the 'scsi_host' adapter")); return -1; } if (scsi_host->name && scsi_host->has_parent) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("Both 'name' and 'parent' cannot be specified " - "for the 'scsi_host' adapter")); + _("Both 'name' and 'parent' cannot be specified for the 'scsi_host' adapter")); return -1; } diff --git a/src/conf/virdomainjob.c b/src/conf/virdomainjob.c index 2644a793f8..38f08f1d18 100644 --- a/src/conf/virdomainjob.c +++ b/src/conf/virdomainjob.c @@ -492,8 +492,7 @@ virDomainObjBeginJobInternal(virDomainObj *obj, agentBlocker); } else { virReportError(VIR_ERR_OPERATION_FAILED, "%s", - _("cannot acquire state change lock " - "due to max_queued limit")); + _("cannot acquire state change lock due to max_queued limit")); } ret = -2; } else { diff --git a/src/conf/virnetworkobj.c b/src/conf/virnetworkobj.c index b8b86da06f..5d108a8fca 100644 --- a/src/conf/virnetworkobj.c +++ b/src/conf/virnetworkobj.c @@ -741,8 +741,7 @@ virNetworkObjConfigChangeSetup(virNetworkObj *obj, if (flags & VIR_NETWORK_UPDATE_AFFECT_CONFIG) { if (!obj->persistent) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("cannot change persistent config of a " - "transient network")); + _("cannot change persistent config of a transient network")); return -1; } /* this should already have been done by the driver, but do it -- 2.41.0

Error messages are exempt from the 80 columns rule. Move them onto one line. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/cpu/cpu_x86.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/cpu/cpu_x86.c b/src/cpu/cpu_x86.c index b9513e24d5..7a7f3b409d 100644 --- a/src/cpu/cpu_x86.c +++ b/src/cpu/cpu_x86.c @@ -1899,8 +1899,7 @@ x86Compute(virCPUDef *host, result = x86ModelCompare(host_model, cpu_require); if (result == SUBSET || result == UNRELATED) { x86DataSubtract(&cpu_require->data, &host_model->data); - virX86CpuIncompatible(N_("Host CPU does not provide required " - "features"), + virX86CpuIncompatible(N_("Host CPU does not provide required features"), &cpu_require->data); return VIR_CPU_COMPARE_INCOMPATIBLE; } @@ -1919,8 +1918,7 @@ x86Compute(virCPUDef *host, if (ret == VIR_CPU_COMPARE_SUPERSET && cpu->type == VIR_CPU_TYPE_GUEST && cpu->match == VIR_CPU_MATCH_STRICT) { - virX86CpuIncompatible(N_("Host CPU does not strictly match guest CPU: " - "Extra features"), + virX86CpuIncompatible(N_("Host CPU does not strictly match guest CPU: Extra features"), &diff->data); return VIR_CPU_COMPARE_INCOMPATIBLE; } -- 2.41.0

Error messages are exempt from the 80 columns rule. Move them onto one line. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/esx/esx_driver.c | 21 +++++++-------------- src/esx/esx_network_driver.c | 3 +-- src/esx/esx_storage_backend_vmfs.c | 3 +-- src/esx/esx_util.c | 3 +-- src/esx/esx_vi.c | 19 ++++++------------- src/esx/esx_vi_types.c | 3 +-- 6 files changed, 17 insertions(+), 35 deletions(-) diff --git a/src/esx/esx_driver.c b/src/esx/esx_driver.c index b243bbf411..554fb3e18f 100644 --- a/src/esx/esx_driver.c +++ b/src/esx/esx_driver.c @@ -2916,8 +2916,7 @@ esxDomainDefineXMLFlags(virConnectPtr conn, const char *xml, unsigned int flags) if (virtualMachine) { /* FIXME */ virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Domain already exists, editing existing domains is not " - "supported yet")); + _("Domain already exists, editing existing domains is not supported yet")); goto cleanup; } @@ -2952,8 +2951,7 @@ esxDomainDefineXMLFlags(virConnectPtr conn, const char *xml, unsigned int flags) */ if (def->ndisks < 1) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Domain XML doesn't contain any disks, cannot deduce " - "datastore and path for VMX file")); + _("Domain XML doesn't contain any disks, cannot deduce datastore and path for VMX file")); goto cleanup; } @@ -2967,16 +2965,14 @@ esxDomainDefineXMLFlags(virConnectPtr conn, const char *xml, unsigned int flags) if (!disk) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Domain XML doesn't contain any file-based harddisks, " - "cannot deduce datastore and path for VMX file")); + _("Domain XML doesn't contain any file-based harddisks, cannot deduce datastore and path for VMX file")); goto cleanup; } src = virDomainDiskGetSource(disk); if (!src) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("First file-based harddisk has no source, cannot deduce " - "datastore and path for VMX file")); + _("First file-based harddisk has no source, cannot deduce datastore and path for VMX file")); goto cleanup; } @@ -3241,8 +3237,7 @@ esxDomainSetAutostart(virDomainPtr domain, int autostart) powerInfo = powerInfo->_next) { if (STRNEQ(powerInfo->key->value, virtualMachine->obj->value)) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("Cannot enable general autostart option " - "without affecting other domains")); + _("Cannot enable general autostart option without affecting other domains")); goto cleanup; } } @@ -3685,8 +3680,7 @@ esxDomainMigratePerform(virDomainPtr domain, if (STRCASENEQ(priv->vCenter->ipAddress, parsedUri->server)) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("Migration source and destination have to refer to " - "the same vCenter")); + _("Migration source and destination have to refer to the same vCenter")); goto cleanup; } @@ -3734,8 +3728,7 @@ esxDomainMigratePerform(virDomainPtr domain, eventList->fullFormattedMessage); } else { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Could not migrate domain, validation reported a " - "problem")); + _("Could not migrate domain, validation reported a problem")); } goto cleanup; diff --git a/src/esx/esx_network_driver.c b/src/esx/esx_network_driver.c index 273147af40..1ee4d6c34f 100644 --- a/src/esx/esx_network_driver.c +++ b/src/esx/esx_network_driver.c @@ -311,8 +311,7 @@ esxNetworkDefineXMLFlags(virConnectPtr conn, const char *xml, if (hostVirtualSwitch) { /* FIXME */ virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("HostVirtualSwitch already exists, editing existing " - "ones is not supported yet")); + _("HostVirtualSwitch already exists, editing existing ones is not supported yet")); goto cleanup; } diff --git a/src/esx/esx_storage_backend_vmfs.c b/src/esx/esx_storage_backend_vmfs.c index 7c5df1c9cd..145aff0c9c 100644 --- a/src/esx/esx_storage_backend_vmfs.c +++ b/src/esx/esx_storage_backend_vmfs.c @@ -726,8 +726,7 @@ esxStorageVolLookupByKey(virConnectPtr conn, const char *key) if (!priv->primary->hasQueryVirtualDiskUuid) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("QueryVirtualDiskUuid not available, " - "cannot lookup storage volume by UUID")); + _("QueryVirtualDiskUuid not available, cannot lookup storage volume by UUID")); return NULL; } diff --git a/src/esx/esx_util.c b/src/esx/esx_util.c index 785701a518..cb9638f360 100644 --- a/src/esx/esx_util.c +++ b/src/esx/esx_util.c @@ -119,8 +119,7 @@ esxUtil_ParseUri(esxUtil_ParsedUri **parsedUri, virURI *uri) if ((tmp = strchr((*parsedUri)->proxy_hostname, ':'))) { if (tmp == (*parsedUri)->proxy_hostname) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("Query parameter 'proxy' doesn't contain a " - "hostname")); + _("Query parameter 'proxy' doesn't contain a hostname")); goto cleanup; } diff --git a/src/esx/esx_vi.c b/src/esx/esx_vi.c index 122e5bed2e..3ecd406e1d 100644 --- a/src/esx/esx_vi.c +++ b/src/esx/esx_vi.c @@ -253,8 +253,7 @@ esxVI_CURL_Perform(esxVI_CURL *curl, const char *url) if (responseCode < 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("curl_easy_getinfo(CURLINFO_RESPONSE_CODE) returned a " - "negative response code")); + _("curl_easy_getinfo(CURLINFO_RESPONSE_CODE) returned a negative response code")); return -1; } @@ -674,15 +673,13 @@ esxVI_MultiCURL_Remove(esxVI_MultiCURL *multi, esxVI_CURL *curl) { if (!curl->handle) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Cannot remove uninitialized CURL handle from a " - "multi handle")); + _("Cannot remove uninitialized CURL handle from a multi handle")); return -1; } if (!curl->multi) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Cannot remove CURL handle from a multi handle when it " - "wasn't added before")); + _("Cannot remove CURL handle from a multi handle when it wasn't added before")); return -1; } @@ -1909,8 +1906,7 @@ esxVI_EnsureSession(esxVI_Context *ctx) } } else if (STRNEQ(ctx->session->key, currentSession->key)) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Key of the current session differs from the key at " - "last login")); + _("Key of the current session differs from the key at last login")); goto cleanup; } @@ -4220,13 +4216,10 @@ esxVI_WaitForTaskCompletion(esxVI_Context *ctx, if (taskInfo->cancelable == esxVI_Boolean_True) { if (esxVI_CancelTask(ctx, task) < 0 && blocked) { - VIR_ERROR(_("Cancelable task is blocked by an " - "unanswered question but cancellation " - "failed")); + VIR_ERROR(_("Cancelable task is blocked by an unanswered question but cancellation failed")); } } else if (blocked) { - VIR_ERROR(_("Non-cancelable task is blocked by an " - "unanswered question")); + VIR_ERROR(_("Non-cancelable task is blocked by an unanswered question")); } /* FIXME: Enable error reporting here again */ diff --git a/src/esx/esx_vi_types.c b/src/esx/esx_vi_types.c index 96c131f618..9386727fcf 100644 --- a/src/esx/esx_vi_types.c +++ b/src/esx/esx_vi_types.c @@ -1444,8 +1444,7 @@ esxVI_DateTime_Deserialize(xmlNodePtr node, esxVI_DateTime **dateTime) if (!(*dateTime)->value) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("XML node doesn't contain text, expecting an " - "xsd:dateTime value")); + _("XML node doesn't contain text, expecting an xsd:dateTime value")); goto failure; } -- 2.41.0

Error messages are exempt from the 80 columns rule. Move them onto one line. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/hypervisor/domain_cgroup.c | 3 +-- src/hypervisor/virhostdev.c | 9 +++------ 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/src/hypervisor/domain_cgroup.c b/src/hypervisor/domain_cgroup.c index 20ad96b11c..2b9a1cc9b1 100644 --- a/src/hypervisor/domain_cgroup.c +++ b/src/hypervisor/domain_cgroup.c @@ -233,8 +233,7 @@ virDomainCgroupSetMemoryLimitParameters(virCgroup *cgroup, if (mem_limit > swap_limit) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("memory hard_limit tunable value must be lower " - "than or equal to swap_hard_limit")); + _("memory hard_limit tunable value must be lower than or equal to swap_hard_limit")); return -1; } } diff --git a/src/hypervisor/virhostdev.c b/src/hypervisor/virhostdev.c index b95d6bf3d6..4672bd8785 100644 --- a/src/hypervisor/virhostdev.c +++ b/src/hypervisor/virhostdev.c @@ -423,8 +423,7 @@ virHostdevSaveNetConfig(virDomainHostdevDef *hostdev, if (virHostdevIsVirtualFunction(hostdev) != 1) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Interface type hostdev is currently supported on" - " SR-IOV Virtual Functions only")); + _("Interface type hostdev is currently supported on SR-IOV Virtual Functions only")); return -1; } @@ -511,8 +510,7 @@ virHostdevRestoreNetConfig(virDomainHostdevDef *hostdev, if (virHostdevIsVirtualFunction(hostdev) != 1) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Interface type hostdev is currently supported on" - " SR-IOV Virtual Functions only")); + _("Interface type hostdev is currently supported on SR-IOV Virtual Functions only")); return -1; } @@ -688,8 +686,7 @@ virHostdevPreparePCIDevicesImpl(virHostdevManager *mgr, if (hdrType != VIR_PCI_HEADER_ENDPOINT) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Non-endpoint PCI devices cannot be assigned " - "to guests")); + _("Non-endpoint PCI devices cannot be assigned to guests")); goto cleanup; } -- 2.41.0

Error messages are exempt from the 80 columns rule. Move them onto one line. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/libxl/libxl_conf.c | 12 ++++-------- src/libxl/libxl_driver.c | 6 ++---- src/libxl/libxl_migration.c | 11 ++++------- 3 files changed, 10 insertions(+), 19 deletions(-) diff --git a/src/libxl/libxl_conf.c b/src/libxl/libxl_conf.c index 14ad320023..3ffb46fddd 100644 --- a/src/libxl/libxl_conf.c +++ b/src/libxl/libxl_conf.c @@ -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) + diff --git a/src/libxl/libxl_driver.c b/src/libxl/libxl_driver.c index 079922dd32..c8ca903050 100644 --- a/src/libxl/libxl_driver.c +++ b/src/libxl/libxl_driver.c @@ -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; } diff --git a/src/libxl/libxl_migration.c b/src/libxl/libxl_migration.c index a91091f5e8..f5dee7627b 100644 --- a/src/libxl/libxl_migration.c +++ b/src/libxl/libxl_migration.c @@ -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; } -- 2.41.0

Error messages are exempt from the 80 columns rule. Move them onto one line. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/locking/lock_driver_sanlock.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/locking/lock_driver_sanlock.c b/src/locking/lock_driver_sanlock.c index dc24862a6f..a07f3652c1 100644 --- a/src/locking/lock_driver_sanlock.c +++ b/src/locking/lock_driver_sanlock.c @@ -831,8 +831,7 @@ virLockManagerSanlockRegisterKillscript(int sock, VIR_FREE(err); } else { virReportSystemError(-rv, "%s", - _("Failed to register lock failure" - " action")); + _("Failed to register lock failure action")); } return -1; } -- 2.41.0

Error messages are exempt from the 80 columns rule. Move them onto one line. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/lxc/lxc_container.c | 3 +-- src/lxc/lxc_driver.c | 3 +-- src/lxc/lxc_native.c | 3 +-- src/lxc/lxc_process.c | 3 +-- 4 files changed, 4 insertions(+), 8 deletions(-) diff --git a/src/lxc/lxc_container.c b/src/lxc/lxc_container.c index 19d4f92728..21220661f7 100644 --- a/src/lxc/lxc_container.c +++ b/src/lxc/lxc_container.c @@ -2182,8 +2182,7 @@ int lxcContainerStart(virDomainDef *def, } else { if (lxcNeedNetworkNamespace(def)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Config asks for inherit net namespace " - "as well as private network interfaces")); + _("Config asks for inherit net namespace as well as private network interfaces")); goto cleanup; } VIR_DEBUG("Inheriting a net namespace"); diff --git a/src/lxc/lxc_driver.c b/src/lxc/lxc_driver.c index f284798f1c..f3d3e4eb50 100644 --- a/src/lxc/lxc_driver.c +++ b/src/lxc/lxc_driver.c @@ -654,8 +654,7 @@ static int lxcDomainSetMemoryFlags(virDomainPtr dom, unsigned long newmem, if (flags & VIR_DOMAIN_MEM_MAXIMUM) { if (def) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("Cannot resize the max memory " - "on an active domain")); + _("Cannot resize the max memory on an active domain")); goto endjob; } diff --git a/src/lxc/lxc_native.c b/src/lxc/lxc_native.c index 0ae208ef11..5a63efc35f 100644 --- a/src/lxc/lxc_native.c +++ b/src/lxc/lxc_native.c @@ -1126,8 +1126,7 @@ lxcParseConfigString(const char *config, if (virConfGetValue(properties, "lxc.mount.fstab") || virConfGetValue(properties, "lxc.mount")) { virReportError(VIR_ERR_ARGUMENT_UNSUPPORTED, "%s", - _("lxc.mount.fstab or lxc.mount found, use " - "lxc.mount.entry lines instead")); + _("lxc.mount.fstab or lxc.mount found, use lxc.mount.entry lines instead")); return NULL; } diff --git a/src/lxc/lxc_process.c b/src/lxc/lxc_process.c index 04642b56dd..20cd3a3d57 100644 --- a/src/lxc/lxc_process.c +++ b/src/lxc/lxc_process.c @@ -452,8 +452,7 @@ static int virLXCProcessSetupNamespaceNet(int ns_type, const char *name) int fd; if (ns_type != VIR_LXC_DOMAIN_NAMESPACE_SHARENET) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("'netns' namespace source can only be " - "used with sharenet")); + _("'netns' namespace source can only be used with sharenet")); return -1; } -- 2.41.0

Error messages are exempt from the 80 columns rule. Move them onto one line. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/network/bridge_driver.c | 14 ++++---------- src/network/bridge_driver_linux.c | 10 +--------- 2 files changed, 5 insertions(+), 19 deletions(-) diff --git a/src/network/bridge_driver.c b/src/network/bridge_driver.c index 9eb543a0a3..e1cdc83025 100644 --- a/src/network/bridge_driver.c +++ b/src/network/bridge_driver.c @@ -1302,8 +1302,7 @@ networkDnsmasqConfContents(virNetworkObj *obj, if (ipdef->nranges || ipdef->nhosts) { if (ipv4def) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("For IPv4, multiple DHCP definitions " - "cannot be specified.")); + _("For IPv4, multiple DHCP definitions cannot be specified.")); return -1; } else { ipv4def = ipdef; @@ -1316,8 +1315,7 @@ networkDnsmasqConfContents(virNetworkObj *obj, if (ipdef->nranges || ipdef->nhosts) { if (ipv6def) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("For IPv6, multiple DHCP definitions " - "cannot be specified.")); + _("For IPv6, multiple DHCP definitions cannot be specified.")); return -1; } else { ipv6def = ipdef; @@ -2869,9 +2867,7 @@ networkValidate(virNetworkDriverState *driver, if (ipdef->nranges || ipdef->nhosts) { if (ipv4def) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Multiple IPv4 dhcp sections found -- " - "dhcp is supported only for a " - "single IPv4 address on each network")); + _("Multiple IPv4 dhcp sections found -- dhcp is supported only for a single IPv4 address on each network")); return -1; } else { ipv4def = true; @@ -2882,9 +2878,7 @@ networkValidate(virNetworkDriverState *driver, if (ipdef->nranges || ipdef->nhosts) { if (ipv6def) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Multiple IPv6 dhcp sections found -- " - "dhcp is supported only for a " - "single IPv6 address on each network")); + _("Multiple IPv6 dhcp sections found -- dhcp is supported only for a single IPv6 address on each network")); return -1; } else { ipv6def = true; diff --git a/src/network/bridge_driver_linux.c b/src/network/bridge_driver_linux.c index 1ef5b9d917..b8893bfed2 100644 --- a/src/network/bridge_driver_linux.c +++ b/src/network/bridge_driver_linux.c @@ -884,15 +884,7 @@ int networkAddFirewallRules(virNetworkDef *def) if (version >= 6000 && virFirewallDGetBackend() == VIR_FIREWALLD_BACKEND_NFTABLES) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("firewalld is set to use the nftables " - "backend, but the required firewalld " - "'libvirt' zone is missing. Either set " - "the firewalld backend to 'iptables', or " - "ensure that firewalld has a 'libvirt' " - "zone by upgrading firewalld to a " - "version supporting rule priorities " - "(0.7.0+) and/or rebuilding " - "libvirt with --with-firewalld-zone")); + _("firewalld is set to use the nftables backend, but the required firewalld 'libvirt' zone is missing. Either set the firewalld backend to 'iptables', or ensure that firewalld has a 'libvirt' zone by upgrading firewalld to a version supporting rule priorities (0.7.0+) and/or rebuilding libvirt with --with-firewalld-zone")); return -1; } } -- 2.41.0

Error messages are exempt from the 80 columns rule. Move them onto one line. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/node_device/node_device_udev.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/node_device/node_device_udev.c b/src/node_device/node_device_udev.c index dfdef483cb..911325600e 100644 --- a/src/node_device/node_device_udev.c +++ b/src/node_device/node_device_udev.c @@ -1889,8 +1889,7 @@ udevEventHandleThread(void *opaque G_GNUC_UNUSED) if (errno != EAGAIN && errno != EWOULDBLOCK && errno != EINVAL) { VIR_WARNINGS_RESET virReportSystemError(errno, "%s", - _("failed to receive device from udev " - "monitor")); + _("failed to receive device from udev monitor")); return; } -- 2.41.0

Error messages are exempt from the 80 columns rule. Move them onto one line. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/nwfilter/nwfilter_dhcpsnoop.c | 12 ++++-------- src/nwfilter/nwfilter_learnipaddr.c | 8 ++------ 2 files changed, 6 insertions(+), 14 deletions(-) diff --git a/src/nwfilter/nwfilter_dhcpsnoop.c b/src/nwfilter/nwfilter_dhcpsnoop.c index 2f89923856..26072ec26e 100644 --- a/src/nwfilter/nwfilter_dhcpsnoop.c +++ b/src/nwfilter/nwfilter_dhcpsnoop.c @@ -1441,9 +1441,7 @@ virNWFilterDHCPSnoopReq(virNWFilterTechDriver *techdriver, /* check that all tools are available for applying the filters (late) */ if (!techdriver->canApplyBasicRules()) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("IP parameter must be provided since " - "snooping the IP address does not work " - "possibly due to missing tools")); + _("IP parameter must be provided since snooping the IP address does not work possibly due to missing tools")); goto exit_snoopreqput; } @@ -1454,8 +1452,7 @@ virNWFilterDHCPSnoopReq(virNWFilterTechDriver *techdriver, &req->binding->mac, dhcpsrvrs, false) < 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("applyDHCPOnlyRules " - "failed - spoofing not protected!")); + _("applyDHCPOnlyRules failed - spoofing not protected!")); goto exit_snoopreqput; } @@ -1990,9 +1987,8 @@ virNWFilterDHCPSnoopReq(virNWFilterTechDriver *techdriver G_GNUC_UNUSED, virNWFilterDriverState *driver G_GNUC_UNUSED) { virReportError(VIR_ERR_INTERNAL_ERROR, - _("libvirt was not compiled with libpcap and \"" - NWFILTER_VARNAME_CTRL_IP_LEARNING - "='dhcp'\" requires it.")); + _("libvirt was not compiled with libpcap and \"%1$s\" requires it"), + NWFILTER_VARNAME_CTRL_IP_LEARNING "='dhcp'"); return -1; } #endif /* WITH_LIBPCAP */ diff --git a/src/nwfilter/nwfilter_learnipaddr.c b/src/nwfilter/nwfilter_learnipaddr.c index 90e9a21a4e..73d8302c13 100644 --- a/src/nwfilter/nwfilter_learnipaddr.c +++ b/src/nwfilter/nwfilter_learnipaddr.c @@ -669,9 +669,7 @@ virNWFilterLearnIPAddress(virNWFilterTechDriver *techdriver, if (!techdriver->canApplyBasicRules()) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("IP parameter must be provided since " - "snooping the IP address does not work " - "possibly due to missing tools")); + _("IP parameter must be provided since snooping the IP address does not work possibly due to missing tools")); return -1; } @@ -717,9 +715,7 @@ virNWFilterLearnIPAddress(virNWFilterTechDriver *techdriver G_GNUC_UNUSED, int howDetect G_GNUC_UNUSED) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("IP parameter must be given since libvirt " - "was not compiled with IP address learning " - "support")); + _("IP parameter must be given since libvirt was not compiled with IP address learning support")); return -1; } #endif /* WITH_LIBPCAP */ -- 2.41.0

Error messages are exempt from the 80 columns rule. Move them onto one line. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/openvz/openvz_driver.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/openvz/openvz_driver.c b/src/openvz/openvz_driver.c index 69e4c9899b..1bd96dfb56 100644 --- a/src/openvz/openvz_driver.c +++ b/src/openvz/openvz_driver.c @@ -2033,8 +2033,7 @@ openvzDomainMigratePrepare3Params(virConnectPtr dconn, if (STRPREFIX(my_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 error; } -- 2.41.0

Error messages are exempt from the 80 columns rule. Move them onto one line. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/qemu/qemu_agent.c | 18 +-- src/qemu/qemu_capabilities.c | 45 +++---- src/qemu/qemu_command.c | 42 ++----- src/qemu/qemu_conf.c | 5 +- src/qemu/qemu_domain.c | 51 +++----- src/qemu/qemu_domain_address.c | 15 +-- src/qemu/qemu_driver.c | 120 ++++++------------ src/qemu/qemu_hostdev.c | 3 +- src/qemu/qemu_hotplug.c | 18 +-- src/qemu/qemu_migration.c | 48 +++---- src/qemu/qemu_migration_params.c | 6 +- src/qemu/qemu_monitor.c | 3 +- src/qemu/qemu_monitor_json.c | 102 +++++---------- src/qemu/qemu_process.c | 20 +-- src/qemu/qemu_snapshot.c | 27 ++-- src/qemu/qemu_tpm.c | 4 +- src/qemu/qemu_validate.c | 209 ++++++++++--------------------- 17 files changed, 243 insertions(+), 493 deletions(-) diff --git a/src/qemu/qemu_agent.c b/src/qemu/qemu_agent.c index 7fc412c17e..f9bcf38dfb 100644 --- a/src/qemu/qemu_agent.c +++ b/src/qemu/qemu_agent.c @@ -160,8 +160,7 @@ qemuAgentOpenUnix(const char *socketpath) if (virSetCloseExec(agentfd) < 0) { virReportSystemError(errno, "%s", - _("Unable to set agent " - "close-on-exec flag")); + _("Unable to set agent close-on-exec flag")); goto error; } @@ -757,8 +756,7 @@ static int qemuAgentSend(qemuAgent *agent, ret = -2; } else { virReportSystemError(errno, "%s", - _("Unable to wait on agent socket " - "condition")); + _("Unable to wait on agent socket condition")); } agent->inSync = false; goto cleanup; @@ -1344,8 +1342,7 @@ qemuAgentGetVCPUs(qemuAgent *agent, if (!entry) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("array element missing in guest-get-vcpus return " - "value")); + _("array element missing in guest-get-vcpus return value")); return -1; } @@ -1862,8 +1859,7 @@ qemuAgentGetFSInfo(qemuAgent *agent, if (!(result = virJSONValueObjectGetString(entry, "mountpoint"))) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("'mountpoint' missing in reply of " - "guest-get-fsinfo")); + _("'mountpoint' missing in reply of guest-get-fsinfo")); goto cleanup; } @@ -2207,8 +2203,7 @@ qemuAgentGetUsers(qemuAgent *agent, if (!entry) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("array element missing in guest-get-users return " - "value")); + _("array element missing in guest-get-users return value")); return -1; } @@ -2522,8 +2517,7 @@ int qemuAgentGetDisks(qemuAgent *agent, if (!entry) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("array element missing in guest-get-disks return " - "value")); + _("array element missing in guest-get-disks return value")); goto error; } diff --git a/src/qemu/qemu_capabilities.c b/src/qemu/qemu_capabilities.c index 05cc11218a..bdb20b47ba 100644 --- a/src/qemu/qemu_capabilities.c +++ b/src/qemu/qemu_capabilities.c @@ -3957,8 +3957,7 @@ virQEMUCapsLoadHostCPUModelInfo(virQEMUCapsAccel *caps, if (!(hostCPU->name = virXMLPropString(hostCPUNode, "model"))) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("missing host CPU model name in QEMU " - "capabilities cache")); + _("missing host CPU model name in QEMU capabilities cache")); return -1; } @@ -3983,16 +3982,14 @@ virQEMUCapsLoadHostCPUModelInfo(virQEMUCapsAccel *caps, if (!(prop->name = virXMLPropString(ctxt->node, "name"))) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("missing 'name' attribute for a host CPU" - " model property in QEMU capabilities cache")); + _("missing 'name' attribute for a host CPU model property in QEMU capabilities cache")); return -1; } if (!(type = virXMLPropString(ctxt->node, "type")) || (val = qemuMonitorCPUPropertyTypeFromString(type)) < 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("missing or invalid CPU model property type " - "in QEMU capabilities cache")); + _("missing or invalid CPU model property type in QEMU capabilities cache")); return -1; } @@ -4109,8 +4106,7 @@ virQEMUCapsLoadCPUModels(virArch arch, for (j = 0; j < nblockers; j++) { if (!(cpu->blockers[j] = virXMLPropString(blockerNodes[j], "name"))) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("missing blocker name in QEMU " - "capabilities cache")); + _("missing blocker name in QEMU capabilities cache")); return -1; } @@ -4254,8 +4250,7 @@ virQEMUCapsParseSEVInfo(virQEMUCaps *qemuCaps, xmlXPathContextPtr ctxt) if (virXPathBoolean("boolean(./sev)", ctxt) == 0) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("missing SEV platform data in QEMU " - "capabilities cache")); + _("missing SEV platform data in QEMU capabilities cache")); return -1; } @@ -4263,30 +4258,26 @@ virQEMUCapsParseSEVInfo(virQEMUCaps *qemuCaps, xmlXPathContextPtr ctxt) if (virXPathUInt("string(./sev/cbitpos)", ctxt, &sev->cbitpos) < 0) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("missing or malformed SEV cbitpos information " - "in QEMU capabilities cache")); + _("missing or malformed SEV cbitpos information in QEMU capabilities cache")); return -1; } if (virXPathUInt("string(./sev/reducedPhysBits)", ctxt, &sev->reduced_phys_bits) < 0) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("missing or malformed SEV reducedPhysBits information " - "in QEMU capabilities cache")); + _("missing or malformed SEV reducedPhysBits information in QEMU capabilities cache")); return -1; } if (!(sev->pdh = virXPathString("string(./sev/pdh)", ctxt))) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("missing SEV pdh information " - "in QEMU capabilities cache")); + _("missing SEV pdh information in QEMU capabilities cache")); return -1; } if (!(sev->cert_chain = virXPathString("string(./sev/certChain)", ctxt))) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("missing SEV certChain information " - "in QEMU capabilities cache")); + _("missing SEV certChain information in QEMU capabilities cache")); return -1; } @@ -4507,28 +4498,24 @@ virQEMUCapsParseGIC(virQEMUCaps *qemuCaps, xmlXPathContextPtr ctxt) if (!(version = virXMLPropString(nodes[i], "version"))) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("missing GIC version " - "in QEMU capabilities cache")); + _("missing GIC version in QEMU capabilities cache")); return -1; } if (virStrToLong_ui(version, NULL, 10, &uintValue) < 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("malformed GIC version " - "in QEMU capabilities cache")); + _("malformed GIC version in QEMU capabilities cache")); return -1; } cap->version = uintValue; if (!(kernel = virXMLPropString(nodes[i], "kernel"))) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("missing in-kernel GIC information " - "in QEMU capabilities cache")); + _("missing in-kernel GIC information in QEMU capabilities cache")); return -1; } if (!(boolValue = STREQ(kernel, "yes")) && STRNEQ(kernel, "no")) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("malformed in-kernel GIC information " - "in QEMU capabilities cache")); + _("malformed in-kernel GIC information in QEMU capabilities cache")); return -1; } if (boolValue) @@ -4536,14 +4523,12 @@ virQEMUCapsParseGIC(virQEMUCaps *qemuCaps, xmlXPathContextPtr ctxt) if (!(emulated = virXMLPropString(nodes[i], "emulated"))) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("missing emulated GIC information " - "in QEMU capabilities cache")); + _("missing emulated GIC information in QEMU capabilities cache")); return -1; } if (!(boolValue = STREQ(emulated, "yes")) && STRNEQ(emulated, "no")) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("malformed emulated GIC information " - "in QEMU capabilities cache")); + _("malformed emulated GIC information in QEMU capabilities cache")); return -1; } if (boolValue) diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c index 6bcf2fdadd..4aa686bfd5 100644 --- a/src/qemu/qemu_command.c +++ b/src/qemu/qemu_command.c @@ -2910,8 +2910,7 @@ qemuBuildLegacyUSBControllerCommandLine(virCommand *cmd, if (nlegacy > 1) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Multiple legacy USB controllers are " - "not supported")); + _("Multiple legacy USB controllers are not supported")); return -1; } @@ -3122,9 +3121,8 @@ qemuBuildMemoryGetDefaultPagesize(virQEMUDriverConfig *cfg, virHugeTLBFS *p; if (!cfg->nhugetlbfs) { - virReportError(VIR_ERR_INTERNAL_ERROR, - "%s", _("hugetlbfs filesystem is not mounted " - "or disabled by administrator config")); + virReportError(VIR_ERR_INTERNAL_ERROR, "%s", + _("hugetlbfs filesystem is not mounted or disabled by administrator config")); return -1; } @@ -3482,8 +3480,7 @@ qemuBuildMemoryBackendProps(virJSONValue **backendProps, mem->source.nvdimm.pmem) { if (!virQEMUCapsGet(priv->qemuCaps, QEMU_CAPS_OBJECT_MEMORY_FILE_PMEM)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("nvdimm pmem property is not available " - "with this QEMU binary")); + _("nvdimm pmem property is not available with this QEMU binary")); return -1; } if (virJSONValueObjectAdd(&props, "b:pmem", true, NULL) < 0) @@ -5747,8 +5744,7 @@ qemuBuildSmbiosCommandLine(virCommand *cmd, if (source->nbaseBoard > 1) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("qemu does not support more than " - "one entry to Type 2 in SMBIOS table")); + _("qemu does not support more than one entry to Type 2 in SMBIOS table")); return -1; } @@ -6242,8 +6238,7 @@ qemuBuildGlobalControllerCommandLine(virCommand *cmd, default: virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("64-bit PCI hole setting is only for root" - " PCI controllers")); + _("64-bit PCI hole setting is only for root PCI controllers")); return -1; } @@ -6782,8 +6777,7 @@ qemuAppendDomainFeaturesMachineParam(virBuffer *buf, case VIR_GIC_VERSION_HOST: if (!hasGICVersionOption) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("gic-version option is not available " - "with this QEMU binary")); + _("gic-version option is not available with this QEMU binary")); return -1; } @@ -8252,9 +8246,7 @@ qemuBuildGraphicsSPICECommandLine(virQEMUDriverConfig *cfg, case VIR_DOMAIN_GRAPHICS_SPICE_CHANNEL_MODE_SECURE: if (!hasSecure) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("spice defaultMode secure requested in XML " - "configuration, but TLS connection is not " - "available")); + _("spice defaultMode secure requested in XML configuration, but TLS connection is not available")); return -1; } virBufferAddLit(&opt, "tls-channel=default,"); @@ -8262,9 +8254,7 @@ qemuBuildGraphicsSPICECommandLine(virQEMUDriverConfig *cfg, case VIR_DOMAIN_GRAPHICS_SPICE_CHANNEL_MODE_INSECURE: if (!hasInsecure) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("spice defaultMode insecure requested in XML " - "configuration, but plaintext connection is not " - "available")); + _("spice defaultMode insecure requested in XML configuration, but plaintext connection is not available")); return -1; } virBufferAddLit(&opt, "plaintext-channel=default,"); @@ -8280,9 +8270,7 @@ qemuBuildGraphicsSPICECommandLine(virQEMUDriverConfig *cfg, case VIR_DOMAIN_GRAPHICS_SPICE_CHANNEL_MODE_SECURE: if (!hasSecure) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("spice secure channels set in XML " - "configuration, but TLS connection is not " - "available")); + _("spice secure channels set in XML configuration, but TLS connection is not available")); return -1; } virBufferAsprintf(&opt, "tls-channel=%s,", @@ -8292,9 +8280,7 @@ qemuBuildGraphicsSPICECommandLine(virQEMUDriverConfig *cfg, case VIR_DOMAIN_GRAPHICS_SPICE_CHANNEL_MODE_INSECURE: if (!hasInsecure) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("spice insecure channels set in XML " - "configuration, but plaintext connection " - "is not available")); + _("spice insecure channels set in XML configuration, but plaintext connection is not available")); return -1; } virBufferAsprintf(&opt, "plaintext-channel=%s,", @@ -9030,8 +9016,7 @@ qemuBuildShmemCommandLine(virCommand *cmd, if (shmem->info.type != VIR_DOMAIN_DEVICE_ADDRESS_TYPE_PCI) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("only 'pci' addresses are supported for the " - "shared memory device")); + _("only 'pci' addresses are supported for the shared memory device")); return -1; } @@ -10027,8 +10012,7 @@ qemuBuildCommandLineValidate(virQEMUDriver *driver, if (sdl > 1 || vnc > 1 || spice > 1 || egl_headless > 1 || dbus > 1) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("only 1 graphics device of each type " - "(sdl, vnc, spice, headless, dbus) is supported")); + _("only 1 graphics device of each type (sdl, vnc, spice, headless, dbus) is supported")); return -1; } diff --git a/src/qemu/qemu_conf.c b/src/qemu/qemu_conf.c index 3f811d064f..94648026fb 100644 --- a/src/qemu/qemu_conf.c +++ b/src/qemu/qemu_conf.c @@ -1548,9 +1548,8 @@ qemuGetDomainHupageMemPath(virQEMUDriver *driver, size_t i = 0; if (!cfg->nhugetlbfs) { - virReportError(VIR_ERR_INTERNAL_ERROR, - "%s", _("hugetlbfs filesystem is not mounted " - "or disabled by administrator config")); + virReportError(VIR_ERR_INTERNAL_ERROR, "%s", + _("hugetlbfs filesystem is not mounted or disabled by administrator config")); return -1; } diff --git a/src/qemu/qemu_domain.c b/src/qemu/qemu_domain.c index 0b2b22a219..03c2aa1002 100644 --- a/src/qemu/qemu_domain.c +++ b/src/qemu/qemu_domain.c @@ -4591,8 +4591,7 @@ qemuDomainDefVcpusPostParse(virDomainDef *def) /* they can be ordered only at the beginning */ if (prevvcpu->hotpluggable == VIR_TRISTATE_BOOL_YES) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("online non-hotpluggable vcpus need to be " - "ordered prior to hotplugable vcpus")); + _("online non-hotpluggable vcpus need to be ordered prior to hotplugable vcpus")); return -1; } @@ -4600,8 +4599,7 @@ qemuDomainDefVcpusPostParse(virDomainDef *def) * Also note that multiple vcpus may share order on some platforms */ if (prevvcpu->order > vcpu->order) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("online non-hotpluggable vcpus must be ordered " - "in ascending order")); + _("online non-hotpluggable vcpus must be ordered in ascending order")); return -1; } } @@ -4644,8 +4642,7 @@ qemuDomainDefSetDefaultCPU(virDomainDef *def, if (STREQ(model, "host") && def->virtType != VIR_DOMAIN_VIRT_KVM) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("QEMU reports invalid default CPU model \"host\" " - "for non-kvm domain virt type")); + _("QEMU reports invalid default CPU model \"host\" for non-kvm domain virt type")); return -1; } @@ -5080,15 +5077,13 @@ qemuDomainValidateStorageSource(virStorageSource *src, if (src->format == VIR_STORAGE_FILE_DIR) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("'directory' storage format is not directly supported by QEMU, " - "use 'dir' disk type instead")); + _("'directory' storage format is not directly supported by QEMU, use 'dir' disk type instead")); return -1; } if (src->format == VIR_STORAGE_FILE_ISO) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("storage format 'iso' is not directly supported by QEMU, " - "use 'raw' instead")); + _("storage format 'iso' is not directly supported by QEMU, use 'raw' instead")); return -1; } @@ -5096,8 +5091,7 @@ qemuDomainValidateStorageSource(virStorageSource *src, actualType != VIR_STORAGE_TYPE_VOLUME && actualType != VIR_STORAGE_TYPE_DIR) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("storage format 'fat' is supported only with 'dir' " - "storage type")); + _("storage format 'fat' is supported only with 'dir' storage type")); return -1; } @@ -5628,23 +5622,20 @@ qemuDomainControllerDefPostParse(virDomainControllerDef *cont, cont->model == VIR_DOMAIN_CONTROLLER_MODEL_PCIE_ROOT) && cont->idx != 0) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("pci-root and pcie-root controllers " - "should have index 0")); + _("pci-root and pcie-root controllers should have index 0")); return -1; } if (cont->model == VIR_DOMAIN_CONTROLLER_MODEL_PCI_EXPANDER_BUS && !qemuDomainIsI440FX(def)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("pci-expander-bus controllers are only supported " - "on 440fx-based machinetypes")); + _("pci-expander-bus controllers are only supported on 440fx-based machinetypes")); return -1; } if (cont->model == VIR_DOMAIN_CONTROLLER_MODEL_PCIE_EXPANDER_BUS && !(qemuDomainIsQ35(def) || qemuDomainIsARMVirt(def))) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("pcie-expander-bus controllers are not supported " - "with this machine type")); + _("pcie-expander-bus controllers are not supported with this machine type")); return -1; } @@ -6129,8 +6120,7 @@ qemuDomainNVDimmAlignSizePseries(virDomainMemoryDef *mem) * smaller than the 256MiB alignment. */ if (guestArea < ppc64AlignSize) { virReportError(VIR_ERR_XML_ERROR, "%s", - _("minimum target size for the NVDIMM " - "must be 256MB plus the label size")); + _("minimum target size for the NVDIMM must be 256MB plus the label size")); return -1; } @@ -7868,8 +7858,7 @@ qemuDomainStorageSourceValidateDepth(virStorageSource *src, diskdst); else virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("backing chains more than 200 layers deep are not " - "supported")); + _("backing chains more than 200 layers deep are not supported")); return -1; } @@ -8785,8 +8774,7 @@ qemuDomainAgentAvailable(virDomainObj *vm, if (priv->agentError) { if (reportError) { virReportError(VIR_ERR_AGENT_UNRESPONSIVE, "%s", - _("QEMU guest agent is not " - "available due to an error")); + _("QEMU guest agent is not available due to an error")); } return false; } @@ -9284,8 +9272,7 @@ qemuDomainDefValidateMemoryHotplugDevice(const virDomainMemoryDef *mem, if (mem->info.type != VIR_DOMAIN_DEVICE_ADDRESS_TYPE_DIMM && mem->info.type != VIR_DOMAIN_DEVICE_ADDRESS_TYPE_NONE) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("only 'dimm' addresses are supported for the " - "pc-dimm device")); + _("only 'dimm' addresses are supported for the pc-dimm device")); return -1; } @@ -9307,8 +9294,7 @@ qemuDomainDefValidateMemoryHotplugDevice(const virDomainMemoryDef *mem, if (mem->info.type != VIR_DOMAIN_DEVICE_ADDRESS_TYPE_PCI && mem->info.type != VIR_DOMAIN_DEVICE_ADDRESS_TYPE_NONE) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("only 'pci' addresses are supported for the " - "virtio-pmem device")); + _("only 'pci' addresses are supported for the virtio-pmem device")); return -1; } @@ -9341,8 +9327,7 @@ qemuDomainDefValidateMemoryHotplugDevice(const virDomainMemoryDef *mem, virDomainNumaGetNodeCount(def->numa) != 0) { if (mem->targetNode == -1) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("target NUMA node needs to be specified for " - "memory device")); + _("target NUMA node needs to be specified for memory device")); return -1; } } @@ -9400,8 +9385,7 @@ qemuDomainDefValidateMemoryHotplug(const virDomainDef *def, if (!virDomainDefHasMemoryHotplug(def)) { if (nmems) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("cannot use/hotplug a memory device when domain " - "'maxMemory' is not defined")); + _("cannot use/hotplug a memory device when domain 'maxMemory' is not defined")); return -1; } @@ -9415,8 +9399,7 @@ qemuDomainDefValidateMemoryHotplug(const virDomainDef *def, * with memory hotplug. */ if (virDomainNumaGetNodeCount(def->numa) == 0) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("At least one numa node has to be configured when " - "enabling memory hotplug")); + _("At least one numa node has to be configured when enabling memory hotplug")); return -1; } } diff --git a/src/qemu/qemu_domain_address.c b/src/qemu/qemu_domain_address.c index 49c5e199fa..e26dc38f76 100644 --- a/src/qemu/qemu_domain_address.c +++ b/src/qemu/qemu_domain_address.c @@ -1633,8 +1633,7 @@ qemuDomainCollectPCIAddress(virDomainDef *def G_GNUC_UNUSED, if (addrs->nbuses > 0 && !(addrs->buses[0].flags & VIR_PCI_CONNECT_TYPE_PCI_DEVICE)) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Bus 0 must be PCI for integrated PIIX3 " - "USB or IDE controllers")); + _("Bus 0 must be PCI for integrated PIIX3 USB or IDE controllers")); return -1; } return 0; @@ -1809,8 +1808,7 @@ qemuDomainValidateDevicePCISlotsPIIX3(virDomainDef *def, if (!virPCIDeviceAddressEqual(&cont->info.addr.pci, &primaryIDEAddr)) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Primary IDE controller must have PCI " - "address 0:0:1.1")); + _("Primary IDE controller must have PCI address 0:0:1.1")); return -1; } } else { @@ -1825,8 +1823,7 @@ qemuDomainValidateDevicePCISlotsPIIX3(virDomainDef *def, if (!virPCIDeviceAddressEqual(&cont->info.addr.pci, &piix3USBAddr)) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("PIIX3 USB controller at index 0 must " - "have PCI address 0:0:1.2")); + _("PIIX3 USB controller at index 0 must have PCI address 0:0:1.2")); return -1; } } else { @@ -1919,8 +1916,7 @@ qemuDomainValidateDevicePCISlotsQ35(virDomainDef *def, if (!virPCIDeviceAddressEqual(&cont->info.addr.pci, &primarySATAAddr)) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Primary SATA controller must have " - "PCI address 0:0:1f.2")); + _("Primary SATA controller must have PCI address 0:0:1f.2")); return -1; } } else { @@ -3053,8 +3049,7 @@ qemuDomainUSBAddressAddHubs(virDomainDef *def) if (data.count > 0 && !virDomainDefHasUSB(def)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("USB is disabled for this domain, but USB devices " - "are present in the domain XML")); + _("USB is disabled for this domain, but USB devices are present in the domain XML")); return -1; } diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_driver.c index 5db42f0753..0d4da937b0 100644 --- a/src/qemu/qemu_driver.c +++ b/src/qemu/qemu_driver.c @@ -2198,8 +2198,7 @@ static int qemuDomainSetMemoryFlags(virDomainPtr dom, unsigned long newmem, if (def) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("cannot resize the maximum memory on an " - "active domain")); + _("cannot resize the maximum memory on an active domain")); goto endjob; } @@ -2208,16 +2207,14 @@ static int qemuDomainSetMemoryFlags(virDomainPtr dom, unsigned long newmem, * is no way to change the individual node sizes with this API */ if (virDomainNumaGetNodeCount(persistentDef->numa) > 0) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("initial memory size of a domain with NUMA " - "nodes cannot be modified with this API")); + _("initial memory size of a domain with NUMA nodes cannot be modified with this API")); goto endjob; } if (persistentDef->mem.max_memory && persistentDef->mem.max_memory < newmem) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("cannot set initial memory size greater than " - "the maximum memory size")); + _("cannot set initial memory size greater than the maximum memory size")); goto endjob; } @@ -2274,8 +2271,7 @@ static int qemuDomainSetMemoryFlags(virDomainPtr dom, unsigned long newmem, /* Lack of balloon support is a fatal error */ if (r == 0) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("Unable to change memory of active domain without " - "the balloon device and guest OS balloon driver")); + _("Unable to change memory of active domain without the balloon device and guest OS balloon driver")); goto endjob; } } @@ -2341,8 +2337,7 @@ static int qemuDomainSetMemoryStatsPeriod(virDomainPtr dom, int period, if (def) { if (!virDomainDefHasMemballoon(def)) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("No memory balloon device configured, " - "can not set the collection period")); + _("No memory balloon device configured, can not set the collection period")); goto endjob; } @@ -2362,8 +2357,7 @@ static int qemuDomainSetMemoryStatsPeriod(virDomainPtr dom, int period, if (persistentDef) { if (!virDomainDefHasMemballoon(persistentDef)) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("No memory balloon device configured, " - "can not set the collection period")); + _("No memory balloon device configured, can not set the collection period")); goto endjob; } persistentDef->memballoon->period = period; @@ -3141,8 +3135,7 @@ doCoreDump(virQEMUDriver *driver, } else { if (dumpformat != VIR_DOMAIN_CORE_DUMP_FORMAT_RAW) { virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("kdump-compressed format is only supported with " - "memory-only dump")); + _("kdump-compressed format is only supported with memory-only dump")); goto cleanup; } @@ -4166,8 +4159,7 @@ qemuDomainSetVcpusMax(virQEMUDriver *driver, if (virDomainNumaGetCPUCountTotal(persistentDef->numa) > nvcpus) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("Number of CPUs in <numa> exceeds the desired " - "maximum vcpu count")); + _("Number of CPUs in <numa> exceeds the desired maximum vcpu count")); return -1; } @@ -4514,8 +4506,7 @@ qemuDomainPinEmulator(virDomainPtr dom, if (virDomainCgroupSetupCpusetCpus(cgroup_emulator, pcpumap) < 0) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("failed to set cpuset.cpus in cgroup" - " for emulator threads")); + _("failed to set cpuset.cpus in cgroup for emulator threads")); goto endjob; } } @@ -4665,8 +4656,7 @@ qemuDomainGetVcpusFlags(virDomainPtr dom, unsigned int flags) if (!virDomainObjIsActive(vm)) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("vCPU count provided by the guest agent can only be " - "requested for live domains")); + _("vCPU count provided by the guest agent can only be requested for live domains")); goto endjob; } @@ -6539,14 +6529,12 @@ qemuDomainUndefineFlags(virDomainPtr dom, if (flags & VIR_DOMAIN_UNDEFINE_MANAGED_SAVE) { if (unlink(name) < 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Failed to remove domain managed " - "save image")); + _("Failed to remove domain managed save image")); goto endjob; } } 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 endjob; } } @@ -10635,8 +10623,7 @@ qemuDomainMigratePrepare2(virConnectPtr dconn, * VIR_MIGRATE_TUNNELLED set */ virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Tunnelled migration requested but invalid " - "RPC method called")); + _("Tunnelled migration requested but invalid RPC method called")); return -1; } @@ -10865,8 +10852,7 @@ qemuDomainMigratePrepare3(virConnectPtr dconn, * VIR_MIGRATE_TUNNELLED set */ virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Tunnelled migration requested but invalid " - "RPC method called")); + _("Tunnelled migration requested but invalid RPC method called")); return -1; } @@ -10952,24 +10938,21 @@ qemuDomainMigratePrepare3Params(virConnectPtr dconn, nmigrate_disks > 0) { if (uri_in && STRPREFIX(uri_in, "unix:") && !nbdURI) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("NBD URI must be supplied when " - "migration URI uses UNIX transport method")); + _("NBD URI must be supplied when migration URI uses UNIX transport method")); return -1; } } if (nbdURI && nbdPort) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("Both port and URI requested for disk migration " - "while being mutually exclusive")); + _("Both port and URI requested for disk migration while being mutually exclusive")); return -1; } if (listenAddress) { if (uri_in && STRPREFIX(uri_in, "unix:")) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("Usage of listen-address is forbidden when " - "migration URI uses UNIX transport method")); + _("Usage of listen-address is forbidden when migration URI uses UNIX transport method")); return -1; } } else { @@ -10981,8 +10964,7 @@ qemuDomainMigratePrepare3Params(virConnectPtr dconn, * VIR_MIGRATE_TUNNELLED set */ virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Tunnelled migration requested but invalid " - "RPC method called")); + _("Tunnelled migration requested but invalid RPC method called")); return -1; } @@ -11201,16 +11183,14 @@ qemuDomainMigratePerform3Params(virDomainPtr dom, if (nbdURI && nbdPort) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("Both port and URI requested for disk migration " - "while being mutually exclusive")); + _("Both port and URI requested for disk migration while being mutually exclusive")); goto cleanup; } if (listenAddress) { if (uri && STRPREFIX(uri, "unix:")) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("Usage of listen-address is forbidden when " - "migration URI uses UNIX transport method")); + _("Usage of listen-address is forbidden when migration URI uses UNIX transport method")); return -1; } } @@ -11226,8 +11206,7 @@ qemuDomainMigratePerform3Params(virDomainPtr dom, nmigrate_disks > 0) { if (uri && STRPREFIX(uri, "unix:") && !nbdURI) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("NBD URI must be supplied when " - "migration URI uses UNIX transport method")); + _("NBD URI must be supplied when migration URI uses UNIX transport method")); return -1; } } @@ -11991,8 +11970,7 @@ qemuDomainGetJobStatsInternal(virDomainObj *vm, if (vm->job->asyncJob == VIR_ASYNC_JOB_MIGRATION_IN) { virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("migration statistics are available only on " - "the source host")); + _("migration statistics are available only on the source host")); return -1; } @@ -12192,14 +12170,12 @@ qemuDomainAbortJobFlags(virDomainPtr dom, case VIR_ASYNC_JOB_MIGRATION_IN: virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("cannot abort incoming migration;" - " use virDomainDestroy instead")); + _("cannot abort incoming migration; use virDomainDestroy instead")); break; case VIR_ASYNC_JOB_START: virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("cannot abort VM start;" - " use virDomainDestroy instead")); + _("cannot abort VM start; use virDomainDestroy instead")); break; case VIR_ASYNC_JOB_MIGRATION_OUT: @@ -12337,8 +12313,7 @@ qemuDomainMigrateGetMaxDowntime(virDomainPtr dom, if (rc == 1) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("Querying migration downtime is not supported by " - "QEMU binary")); + _("Querying migration downtime is not supported by QEMU binary")); goto endjob; } @@ -12378,8 +12353,7 @@ qemuDomainMigrateGetCompressionCache(virDomainPtr dom, if (!qemuMigrationCapsGet(vm, QEMU_MIGRATION_CAP_XBZRLE)) { virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("Compressed migration is not supported by " - "QEMU binary")); + _("Compressed migration is not supported by QEMU binary")); goto endjob; } @@ -12427,8 +12401,7 @@ qemuDomainMigrateSetCompressionCache(virDomainPtr dom, if (!qemuMigrationCapsGet(vm, QEMU_MIGRATION_CAP_XBZRLE)) { virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("Compressed migration is not supported by " - "QEMU binary")); + _("Compressed migration is not supported by QEMU binary")); goto endjob; } @@ -12559,8 +12532,7 @@ qemuDomainMigrationGetPostcopyBandwidth(virDomainObj *vm, if (rc == 1) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("querying maximum post-copy migration speed is " - "not supported by QEMU binary")); + _("querying maximum post-copy migration speed is not supported by QEMU binary")); goto cleanup; } @@ -12644,15 +12616,13 @@ qemuDomainMigrateStartPostCopy(virDomainPtr dom, if (vm->job->asyncJob != VIR_ASYNC_JOB_MIGRATION_OUT) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("post-copy can only be started while " - "outgoing migration is in progress")); + _("post-copy can only be started while outgoing migration is in progress")); goto endjob; } if (!(vm->job->apiFlags & VIR_MIGRATE_POSTCOPY)) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("switching to post-copy requires migration to be " - "started with VIR_MIGRATE_POSTCOPY flag")); + _("switching to post-copy requires migration to be started with VIR_MIGRATE_POSTCOPY flag")); goto endjob; } @@ -13584,8 +13554,7 @@ qemuDomainBlockPullCommon(virDomainObj *vm, if (flags & VIR_DOMAIN_BLOCK_REBASE_RELATIVE && !base) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("flag VIR_DOMAIN_BLOCK_REBASE_RELATIVE is valid only " - "with non-null base")); + _("flag VIR_DOMAIN_BLOCK_REBASE_RELATIVE is valid only with non-null base")); goto cleanup; } @@ -13972,8 +13941,7 @@ qemuDomainBlockCopyValidateMirror(virStorageSource *mirror, if (virStorageSourceAccess(mirror, F_OK) < 0) { if (errno != ENOENT) { virReportSystemError(errno, "%s", - _("unable to verify existence of " - "block copy target")); + _("unable to verify existence of block copy target")); return -1; } @@ -14211,8 +14179,7 @@ qemuDomainBlockCopyCommon(virDomainObj *vm, if (disk->src->shared && !disk->src->readonly && !qemuBlockStorageSourceSupportsConcurrentAccess(mirror)) { virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("can't pivot a shared disk to a storage volume not " - "supporting sharing")); + _("can't pivot a shared disk to a storage volume not supporting sharing")); goto endjob; } @@ -14919,8 +14886,7 @@ qemuDomainCheckBlockIoTuneReset(virDomainDiskDef *disk, if (newiotune->group_name && STRNEQ_NULLABLE(newiotune->group_name, disk->blkdeviotune.group_name)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("creating a new group/updating existing with all" - " tune parameters zero is not supported")); + _("creating a new group/updating existing with all tune parameters zero is not supported")); return -1; } @@ -15099,32 +15065,28 @@ qemuDomainSetBlockIoTune(virDomainPtr dom, if ((info.total_bytes_sec && info.read_bytes_sec) || (info.total_bytes_sec && info.write_bytes_sec)) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("total and read/write of bytes_sec " - "cannot be set at the same time")); + _("total and read/write of bytes_sec cannot be set at the same time")); goto endjob; } if ((info.total_iops_sec && info.read_iops_sec) || (info.total_iops_sec && info.write_iops_sec)) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("total and read/write of iops_sec " - "cannot be set at the same time")); + _("total and read/write of iops_sec cannot be set at the same time")); goto endjob; } if ((info.total_bytes_sec_max && info.read_bytes_sec_max) || (info.total_bytes_sec_max && info.write_bytes_sec_max)) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("total and read/write of bytes_sec_max " - "cannot be set at the same time")); + _("total and read/write of bytes_sec_max cannot be set at the same time")); goto endjob; } if ((info.total_iops_sec_max && info.read_iops_sec_max) || (info.total_iops_sec_max && info.write_iops_sec_max)) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("total and read/write of iops_sec_max " - "cannot be set at the same time")); + _("total and read/write of iops_sec_max cannot be set at the same time")); goto endjob; } @@ -15916,8 +15878,7 @@ qemuDomainFSTrim(virDomainPtr dom, if (mountPoint) { virReportError(VIR_ERR_ARGUMENT_UNSUPPORTED, "%s", - _("Specifying mount point " - "is not supported for now")); + _("Specifying mount point is not supported for now")); return -1; } @@ -16322,8 +16283,7 @@ qemuDomainSetTime(virDomainPtr dom, !virQEMUCapsGet(priv->qemuCaps, QEMU_CAPS_RTC_RESET_REINJECTION)) { virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("cannot set time: qemu doesn't support " - "rtc-reset-reinjection command")); + _("cannot set time: qemu doesn't support rtc-reset-reinjection command")); goto cleanup; } diff --git a/src/qemu/qemu_hostdev.c b/src/qemu/qemu_hostdev.c index f329442f8c..4992c23ee0 100644 --- a/src/qemu/qemu_hostdev.c +++ b/src/qemu/qemu_hostdev.c @@ -245,8 +245,7 @@ qemuHostdevPrepareMediatedDevices(virQEMUDriver *driver, if (virHostdevIsMdevDevice(hostdevs[i])) { if (!supportsVFIO) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Mediated host device assignment requires " - "VFIO support")); + _("Mediated host device assignment requires VFIO support")); return -1; } break; diff --git a/src/qemu/qemu_hotplug.c b/src/qemu/qemu_hotplug.c index d7d1db8ecc..5a25f81d7a 100644 --- a/src/qemu/qemu_hotplug.c +++ b/src/qemu/qemu_hotplug.c @@ -6363,8 +6363,7 @@ qemuDomainHotplugDelVcpu(virQEMUDriver *driver, if ((rc = qemuDomainWaitForDeviceRemoval(vm)) <= 0) { if (rc == 0) virReportError(VIR_ERR_OPERATION_TIMEOUT, "%s", - _("vcpu unplug request timed out. Unplug result " - "must be manually inspected in the domain")); + _("vcpu unplug request timed out. Unplug result must be manually inspected in the domain")); goto cleanup; } @@ -6502,8 +6501,7 @@ qemuDomainSelectHotplugVcpuEntities(virDomainDef *def, if (curvcpus > nvcpus) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("target vm vcpu granularity does not allow the " - "desired vcpu count")); + _("target vm vcpu granularity does not allow the desired vcpu count")); return NULL; } @@ -6529,8 +6527,7 @@ qemuDomainSelectHotplugVcpuEntities(virDomainDef *def, if (curvcpus < nvcpus) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("target vm vcpu granularity does not allow the " - "desired vcpu count")); + _("target vm vcpu granularity does not allow the desired vcpu count")); return NULL; } @@ -6540,8 +6537,7 @@ qemuDomainSelectHotplugVcpuEntities(virDomainDef *def, if (curvcpus != nvcpus) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("failed to find appropriate hotpluggable vcpus to " - "reach the desired target vcpu count")); + _("failed to find appropriate hotpluggable vcpus to reach the desired target vcpu count")); return NULL; } @@ -6848,8 +6844,7 @@ qemuDomainSetVcpuInternal(virQEMUDriver *driver, if (def) { if (!qemuDomainSupportsNewVcpuHotplug(vm)) { virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("this qemu version does not support specific " - "vCPU hotplug")); + _("this qemu version does not support specific vCPU hotplug")); return -1; } @@ -6935,8 +6930,7 @@ qemuDomainChangeDiskLive(virDomainObj *vm, if (disk->device != VIR_DOMAIN_DISK_DEVICE_CDROM && disk->device != VIR_DOMAIN_DISK_DEVICE_FLOPPY) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("disk source can be changed only in removable " - "drives")); + _("disk source can be changed only in removable drives")); return -1; } diff --git a/src/qemu/qemu_migration.c b/src/qemu/qemu_migration.c index 9b490a130d..b209e18dff 100644 --- a/src/qemu/qemu_migration.c +++ b/src/qemu/qemu_migration.c @@ -476,8 +476,7 @@ qemuMigrationDstPrecreateStorage(virDomainObj *vm, if (incremental) { virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("pre-creation of storage targets for incremental " - "storage migration is not supported")); + _("pre-creation of storage targets for incremental storage migration is not supported")); goto cleanup; } @@ -1479,8 +1478,7 @@ qemuMigrationSrcIsAllowed(virDomainObj *vm, if (block) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("domain has 'invtsc' CPU feature but " - "TSC frequency is not specified")); + _("domain has 'invtsc' CPU feature but TSC frequency is not specified")); return false; } } @@ -1493,8 +1491,7 @@ qemuMigrationSrcIsAllowed(virDomainObj *vm, if (mem->model == VIR_DOMAIN_MEMORY_MODEL_DIMM && mem->info.type != VIR_DOMAIN_DEVICE_ADDRESS_TYPE_DIMM) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("domain's dimm info lacks slot ID " - "or base address")); + _("domain's dimm info lacks slot ID or base address")); return false; } @@ -1648,8 +1645,7 @@ qemuMigrationSrcIsSafe(virDomainDef *def, } virReportError(VIR_ERR_MIGRATE_UNSAFE, "%s", - _("Migration may lead to data corruption if disks" - " use cache other than none or directsync")); + _("Migration may lead to data corruption if disks use cache other than none or directsync")); return false; } @@ -2205,8 +2201,7 @@ qemuMigrationDstCheckProtocol(virQEMUCaps *qemuCaps, if (STRPREFIX(migrateFrom, "rdma")) { if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_MIGRATE_RDMA)) { virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("incoming RDMA migration is not supported " - "with this QEMU binary")); + _("incoming RDMA migration is not supported with this QEMU binary")); return -1; } } else if (!STRPREFIX(migrateFrom, "tcp") && @@ -2572,8 +2567,7 @@ qemuMigrationSrcBeginPhase(virQEMUDriver *driver, (!(flags & VIR_MIGRATE_LIVE) || flags & VIR_MIGRATE_PAUSED)) { virReportError(VIR_ERR_ARGUMENT_UNSUPPORTED, "%s", - _("post-copy migration is not supported with non-live " - "or paused migration")); + _("post-copy migration is not supported with non-live or paused migration")); return NULL; } @@ -3733,8 +3727,7 @@ qemuMigrationDstPrepareDirect(virQEMUDriver *driver, 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 cleanup; } @@ -4600,8 +4593,7 @@ qemuMigrationSrcStart(virDomainObj *vm, if (spec->fwdType != MIGRATION_FWD_DIRECT) { if (!tunnelFd) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("tunnelFD argument is required for tunnelled " - "migration")); + _("tunnelFD argument is required for tunnelled migration")); VIR_FORCE_CLOSE(spec->dest.fd.local); VIR_FORCE_CLOSE(spec->dest.fd.qemu); return -1; @@ -5149,14 +5141,12 @@ qemuMigrationSrcPerformNative(virQEMUDriver *driver, if (STREQ(uribits->scheme, "rdma")) { if (!virQEMUCapsGet(priv->qemuCaps, QEMU_CAPS_MIGRATE_RDMA)) { virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("outgoing RDMA migration is not supported " - "with this QEMU binary")); + _("outgoing RDMA migration is not supported with this QEMU binary")); return -1; } if (!virMemoryLimitIsSet(vm->def->mem.hard_limit)) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("cannot start RDMA migration with no memory hard " - "limit set")); + _("cannot start RDMA migration with no memory hard limit set")); return -1; } } @@ -5166,8 +5156,7 @@ qemuMigrationSrcPerformNative(virQEMUDriver *driver, !(flags & VIR_MIGRATE_POSTCOPY_RESUME) && !qemuMigrationParamsTLSHostnameIsSet(migParams)) { virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("Explicit destination hostname is required " - "for TLS migration over UNIX socket")); + _("Explicit destination hostname is required for TLS migration over UNIX socket")); return -1; } @@ -5878,22 +5867,19 @@ qemuMigrationSrcPerformPeer2Peer(virQEMUDriver *driver, if (flags & VIR_MIGRATE_TUNNELLED && uri) { virReportError(VIR_ERR_ARGUMENT_UNSUPPORTED, "%s", - _("migration URI is not supported by tunnelled " - "migration")); + _("migration URI is not supported by tunnelled migration")); goto cleanup; } if (flags & VIR_MIGRATE_TUNNELLED && listenAddress) { virReportError(VIR_ERR_ARGUMENT_UNSUPPORTED, "%s", - _("listen address is not supported by tunnelled " - "migration")); + _("listen address is not supported by tunnelled migration")); goto cleanup; } if (flags & VIR_MIGRATE_TUNNELLED && nbdPort) { virReportError(VIR_ERR_ARGUMENT_UNSUPPORTED, "%s", - _("disk port address is not supported by tunnelled " - "migration")); + _("disk port address is not supported by tunnelled migration")); goto cleanup; } @@ -5956,15 +5942,13 @@ qemuMigrationSrcPerformPeer2Peer(virQEMUDriver *driver, * old-style APIs. */ if (!useParams && (graphicsuri || listenAddress || nmigrate_disks)) { virReportError(VIR_ERR_ARGUMENT_UNSUPPORTED, "%s", - _("Migration APIs with extensible parameters are not " - "supported but extended parameters were passed")); + _("Migration APIs with extensible parameters are not supported but extended parameters were passed")); goto cleanup; } if (offline && !dstOffline) { virReportError(VIR_ERR_ARGUMENT_UNSUPPORTED, "%s", - _("offline migration is not supported by " - "the destination host")); + _("offline migration is not supported by the destination host")); goto cleanup; } diff --git a/src/qemu/qemu_migration_params.c b/src/qemu/qemu_migration_params.c index 807cccd86e..79fe6e97c8 100644 --- a/src/qemu/qemu_migration_params.c +++ b/src/qemu/qemu_migration_params.c @@ -1006,8 +1006,7 @@ qemuMigrationParamsApply(virDomainObj *vm, if (asyncJob == VIR_ASYNC_JOB_NONE) { if (!virBitmapIsAllClear(migParams->caps)) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Migration capabilities can only be set by " - "a migration job")); + _("Migration capabilities can only be set by a migration job")); goto cleanup; } } else if (qemuMigrationParamsApplyCaps(vm, migParams->caps) < 0) { @@ -1091,8 +1090,7 @@ qemuMigrationParamsEnableTLS(virQEMUDriver *driver, if (!jobPriv->migParams->params[QEMU_MIGRATION_PARAM_TLS_CREDS].set) { virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("TLS migration is not supported with this " - "QEMU binary")); + _("TLS migration is not supported with this QEMU binary")); return -1; } diff --git a/src/qemu/qemu_monitor.c b/src/qemu/qemu_monitor.c index 02da1d6dfc..7053539c7d 100644 --- a/src/qemu/qemu_monitor.c +++ b/src/qemu/qemu_monitor.c @@ -976,8 +976,7 @@ qemuMonitorInitBalloonObjectPath(qemuMonitor *mon, /* If we get here, we found the path, but not the property */ virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Property 'guest-stats-polling-interval' " - "not found on memory balloon driver.")); + _("Property 'guest-stats-polling-interval' not found on memory balloon driver.")); cleanup: for (i = 0; i < nprops; i++) diff --git a/src/qemu/qemu_monitor_json.c b/src/qemu/qemu_monitor_json.c index 34c4b543e8..5b9edadcf7 100644 --- a/src/qemu/qemu_monitor_json.c +++ b/src/qemu/qemu_monitor_json.c @@ -2253,8 +2253,7 @@ qemuMonitorJSONBlockStatsCollectData(virJSONValue *dev, if ((stats = virJSONValueObjectGetObject(dev, "stats")) == NULL) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("blockstats stats entry was not " - "in expected format")); + _("blockstats stats entry was not in expected format")); return NULL; } @@ -2425,8 +2424,7 @@ qemuMonitorJSONGetAllBlockStatsInfo(qemuMonitor *mon, if (!dev || virJSONValueGetType(dev) != VIR_JSON_TYPE_OBJECT) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("blockstats device entry was not " - "in expected format")); + _("blockstats device entry was not in expected format")); return -1; } @@ -3025,8 +3023,7 @@ qemuMonitorJSONGetMigrationStatsReply(virJSONValue *reply, &stats->disk_transferred); if (rc < 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("disk migration was active, but " - "'transferred' data was missing")); + _("disk migration was active, but 'transferred' data was missing")); return -1; } @@ -3034,8 +3031,7 @@ qemuMonitorJSONGetMigrationStatsReply(virJSONValue *reply, &stats->disk_remaining); if (rc < 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("disk migration was active, but 'remaining' " - "data was missing")); + _("disk migration was active, but 'remaining' data was missing")); return -1; } @@ -3043,8 +3039,7 @@ qemuMonitorJSONGetMigrationStatsReply(virJSONValue *reply, &stats->disk_total); if (rc < 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("disk migration was active, but 'total' " - "data was missing")); + _("disk migration was active, but 'total' data was missing")); return -1; } @@ -3062,8 +3057,7 @@ qemuMonitorJSONGetMigrationStatsReply(virJSONValue *reply, &stats->xbzrle_cache_size); if (rc < 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("XBZRLE is active, but 'cache-size' data " - "was missing")); + _("XBZRLE is active, but 'cache-size' data was missing")); return -1; } @@ -3071,8 +3065,7 @@ qemuMonitorJSONGetMigrationStatsReply(virJSONValue *reply, &stats->xbzrle_bytes); if (rc < 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("XBZRLE is active, but 'bytes' data " - "was missing")); + _("XBZRLE is active, but 'bytes' data was missing")); return -1; } @@ -3080,8 +3073,7 @@ qemuMonitorJSONGetMigrationStatsReply(virJSONValue *reply, &stats->xbzrle_pages); if (rc < 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("XBZRLE is active, but 'pages' data " - "was missing")); + _("XBZRLE is active, but 'pages' data was missing")); return -1; } @@ -3089,8 +3081,7 @@ qemuMonitorJSONGetMigrationStatsReply(virJSONValue *reply, &stats->xbzrle_cache_miss); if (rc < 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("XBZRLE is active, but 'cache-miss' data " - "was missing")); + _("XBZRLE is active, but 'cache-miss' data was missing")); return -1; } @@ -3098,8 +3089,7 @@ qemuMonitorJSONGetMigrationStatsReply(virJSONValue *reply, &stats->xbzrle_overflow); if (rc < 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("XBZRLE is active, but 'overflow' data " - "was missing")); + _("XBZRLE is active, but 'overflow' data was missing")); return -1; } } @@ -3619,30 +3609,26 @@ qemuMonitorJSONQueryRxFilterParse(virJSONValue *msg, if (!(tmp = virJSONValueObjectGetString(entry, "name"))) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Missing or invalid name " - "in query-rx-filter response")); + _("Missing or invalid name in query-rx-filter response")); return -1; } fil->name = g_strdup(tmp); if ((!(tmp = virJSONValueObjectGetString(entry, "main-mac"))) || virMacAddrParse(tmp, &fil->mac) < 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Missing or invalid 'main-mac' " - "in query-rx-filter response")); + _("Missing or invalid 'main-mac' in query-rx-filter response")); return -1; } if (virJSONValueObjectGetBoolean(entry, "promiscuous", &fil->promiscuous) < 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Missing or invalid 'promiscuous' " - "in query-rx-filter response")); + _("Missing or invalid 'promiscuous' in query-rx-filter response")); return -1; } if (virJSONValueObjectGetBoolean(entry, "broadcast-allowed", &fil->broadcastAllowed) < 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Missing or invalid 'broadcast-allowed' " - "in query-rx-filter response")); + _("Missing or invalid 'broadcast-allowed' in query-rx-filter response")); return -1; } @@ -3650,15 +3636,13 @@ qemuMonitorJSONQueryRxFilterParse(virJSONValue *msg, ((fil->unicast.mode = virNetDevRxFilterModeTypeFromString(tmp)) < 0)) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Missing or invalid 'unicast' " - "in query-rx-filter response")); + _("Missing or invalid 'unicast' in query-rx-filter response")); return -1; } if (virJSONValueObjectGetBoolean(entry, "unicast-overflow", &fil->unicast.overflow) < 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Missing or invalid 'unicast-overflow' " - "in query-rx-filter response")); + _("Missing or invalid 'unicast-overflow' in query-rx-filter response")); return -1; } if ((!(table = virJSONValueObjectGetArray(entry, "unicast-table")))) { @@ -3689,15 +3673,13 @@ qemuMonitorJSONQueryRxFilterParse(virJSONValue *msg, ((fil->multicast.mode = virNetDevRxFilterModeTypeFromString(tmp)) < 0)) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Missing or invalid 'multicast' " - "in query-rx-filter response")); + _("Missing or invalid 'multicast' in query-rx-filter response")); return -1; } if (virJSONValueObjectGetBoolean(entry, "multicast-overflow", &fil->multicast.overflow) < 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Missing or invalid 'multicast-overflow' " - "in query-rx-filter response")); + _("Missing or invalid 'multicast-overflow' in query-rx-filter response")); return -1; } if ((!(table = virJSONValueObjectGetArray(entry, "multicast-table")))) { @@ -3728,8 +3710,7 @@ qemuMonitorJSONQueryRxFilterParse(virJSONValue *msg, ((fil->vlan.mode = virNetDevRxFilterModeTypeFromString(tmp)) < 0)) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Missing or invalid 'vlan' " - "in query-rx-filter response")); + _("Missing or invalid 'vlan' in query-rx-filter response")); return -1; } if ((!(table = virJSONValueObjectGetArray(entry, "vlan-table")))) { @@ -4528,8 +4509,7 @@ qemuMonitorJSONBlockIoThrottleInfo(virJSONValue *io_throttle, if (!temp_dev || virJSONValueGetType(temp_dev) != VIR_JSON_TYPE_OBJECT) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("block_io_throttle device entry " - "was not in expected format")); + _("block_io_throttle device entry was not in expected format")); return -1; } @@ -4538,8 +4518,7 @@ qemuMonitorJSONBlockIoThrottleInfo(virJSONValue *io_throttle, if (!current_drive && !current_qdev) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("block_io_throttle device entry " - "was not in expected format")); + _("block_io_throttle device entry was not in expected format")); return -1; } @@ -4550,8 +4529,7 @@ qemuMonitorJSONBlockIoThrottleInfo(virJSONValue *io_throttle, found = true; if (!(inserted = virJSONValueObjectGetObject(temp_dev, "inserted"))) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("block_io_throttle inserted entry " - "was not in expected format")); + _("block_io_throttle inserted entry was not in expected format")); return -1; } GET_THROTTLE_STATS("bps", total_bytes_sec); @@ -4795,8 +4773,7 @@ int qemuMonitorJSONGetMachines(qemuMonitor *mon, if (virJSONValueObjectHasKey(child, "default-cpu-type")) { if (!(tmp = virJSONValueObjectGetString(child, "default-cpu-type"))) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("query-machines reply has malformed " - "'default-cpu-type' data")); + _("query-machines reply has malformed 'default-cpu-type' data")); goto cleanup; } @@ -4806,8 +4783,7 @@ int qemuMonitorJSONGetMachines(qemuMonitor *mon, if (virJSONValueObjectHasKey(child, "numa-mem-supported")) { if (virJSONValueObjectGetBoolean(child, "numa-mem-supported", &info->numaMemSupported) < 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("query-machines reply has malformed " - "'numa-mem-supported' data")); + _("query-machines reply has malformed 'numa-mem-supported' data")); goto cleanup; } } else { @@ -4817,8 +4793,7 @@ int qemuMonitorJSONGetMachines(qemuMonitor *mon, if (virJSONValueObjectHasKey(child, "default-ram-id")) { if (!(tmp = virJSONValueObjectGetString(child, "default-ram-id"))) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("query-machines reply has malformed " - "'default-ram-id' data")); + _("query-machines reply has malformed 'default-ram-id' data")); goto cleanup; } @@ -5243,8 +5218,7 @@ qemuMonitorJSONGetCPUModelComparison(qemuMonitor *mon, if (!(data_result = virJSONValueObjectGetString(data, "result"))) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("query-cpu-model-comparison reply data was missing " - "'result'")); + _("query-cpu-model-comparison reply data was missing 'result'")); return -1; } @@ -5983,30 +5957,26 @@ qemuMonitorJSONGetSEVCapabilities(qemuMonitor *mon, if (virJSONValueObjectGetNumberUint(caps, "cbitpos", &cbitpos) < 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("query-sev-capabilities reply was missing" - " 'cbitpos' field")); + _("query-sev-capabilities reply was missing 'cbitpos' field")); return -1; } if (virJSONValueObjectGetNumberUint(caps, "reduced-phys-bits", &reduced_phys_bits) < 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("query-sev-capabilities reply was missing" - " 'reduced-phys-bits' field")); + _("query-sev-capabilities reply was missing 'reduced-phys-bits' field")); return -1; } if (!(pdh = virJSONValueObjectGetString(caps, "pdh"))) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("query-sev-capabilities reply was missing" - " 'pdh' field")); + _("query-sev-capabilities reply was missing 'pdh' field")); return -1; } if (!(cert_chain = virJSONValueObjectGetString(caps, "cert-chain"))) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("query-sev-capabilities reply was missing" - " 'cert-chain' field")); + _("query-sev-capabilities reply was missing 'cert-chain' field")); return -1; } @@ -7072,8 +7042,7 @@ qemuMonitorJSONGetIOThreads(qemuMonitor *mon, if (virJSONValueObjectGetNumberInt(child, "thread-id", &info->thread_id) < 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("query-iothreads reply has malformed " - "'thread-id' data")); + _("query-iothreads reply has malformed 'thread-id' data")); goto cleanup; } @@ -7194,8 +7163,7 @@ qemuMonitorJSONGetMemoryDeviceInfo(qemuMonitor *mon, if (!(modelStr = virJSONValueObjectGetString(elem, "type"))) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("query-memory-devices reply data doesn't contain " - "enum type discriminator")); + _("query-memory-devices reply data doesn't contain enum type discriminator")); return -1; } @@ -7206,8 +7174,7 @@ qemuMonitorJSONGetMemoryDeviceInfo(qemuMonitor *mon, if (!(dimminfo = virJSONValueObjectGetObject(elem, "data"))) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("query-memory-devices reply data doesn't " - "contain enum data")); + _("query-memory-devices reply data doesn't contain enum data")); return -1; } @@ -7622,8 +7589,7 @@ qemuMonitorJSONProcessHotpluggableCpusReply(virJSONValue *vcpu, if (entry->node_id == -1 && entry->socket_id == -1 && entry->core_id == -1 && entry->thread_id == -1) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("query-hotpluggable-cpus entry doesn't report " - "topology information")); + _("query-hotpluggable-cpus entry doesn't report topology information")); return -1; } diff --git a/src/qemu/qemu_process.c b/src/qemu/qemu_process.c index a6ed69cfe2..b0eb44e0b9 100644 --- a/src/qemu/qemu_process.c +++ b/src/qemu/qemu_process.c @@ -4237,8 +4237,7 @@ qemuProcessSPICEAllocatePorts(virQEMUDriver *driver, if (needTLSPort || graphics->data.spice.tlsPort == -1) { if (!cfg->spiceTLS) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Auto allocation of spice TLS port requested " - "but spice TLS is disabled in qemu.conf")); + _("Auto allocation of spice TLS port requested but spice TLS is disabled in qemu.conf")); return -1; } @@ -5003,8 +5002,7 @@ qemuProcessGraphicsSetupNetworkAddress(virDomainGraphicsListenDef *glisten, rc = qemuProcessGetNetworkAddress(glisten->network, &glisten->address); if (rc <= -2) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("network-based listen isn't possible, " - "network driver isn't present")); + _("network-based listen isn't possible, network driver isn't present")); return -1; } if (rc < 0) @@ -5355,8 +5353,7 @@ qemuProcessStartValidateGraphics(virDomainObj *vm) case VIR_DOMAIN_GRAPHICS_TYPE_SPICE: if (graphics->nListens > 1) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("QEMU does not support multiple listens for " - "one graphics device.")); + _("QEMU does not support multiple listens for one graphics device.")); return -1; } break; @@ -5412,8 +5409,7 @@ qemuProcessStartValidateDisks(virDomainObj *vm, src->protocol == VIR_STORAGE_NET_PROTOCOL_VXHS && !virQEMUCapsGet(qemuCaps, QEMU_CAPS_VXHS)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("VxHS protocol is not supported with this " - "QEMU binary")); + _("VxHS protocol is not supported with this QEMU binary")); return -1; } @@ -5527,10 +5523,7 @@ qemuProcessStartValidate(virQEMUDriver *driver, VIR_DEBUG("Checking for KVM availability"); if (!virFileExists("/dev/kvm")) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Domain requires KVM, but it is not available. " - "Check that virtualization is enabled in the " - "host BIOS, and host configuration is setup to " - "load the kvm modules.")); + _("Domain requires KVM, but it is not available. Check that virtualization is enabled in the host BIOS, and host configuration is setup to load the kvm modules.")); return -1; } } @@ -9149,8 +9142,7 @@ qemuProcessReconnectHelper(virDomainObj *obj, if (virThreadCreateFull(&thread, false, qemuProcessReconnect, name, false, data) < 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Could not create thread. QEMU initialization " - "might be incomplete")); + _("Could not create thread. QEMU initialization might be incomplete")); /* We can't spawn a thread and thus connect to monitor. Kill qemu. * It's safe to call qemuProcessStop without a job here since there * is no thread that could be doing anything else with the same domain diff --git a/src/qemu/qemu_snapshot.c b/src/qemu/qemu_snapshot.c index d943281e35..ec853686d3 100644 --- a/src/qemu/qemu_snapshot.c +++ b/src/qemu/qemu_snapshot.c @@ -490,8 +490,7 @@ qemuSnapshotPrepareDiskExternalActive(virDomainSnapshotDiskDef *snapdisk, if (domdisk->device == VIR_DOMAIN_DISK_DEVICE_LUN) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("external active snapshots are not supported on scsi " - "passthrough devices")); + _("external active snapshots are not supported on scsi passthrough devices")); return -1; } @@ -766,16 +765,14 @@ qemuSnapshotPrepare(virDomainObj *vm, if ((def->memory == VIR_DOMAIN_SNAPSHOT_LOCATION_INTERNAL && !found_internal) || (found_internal && forbid_internal)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("internal and full system snapshots require all " - "disks to be selected for snapshot")); + _("internal and full system snapshots require all disks to be selected for snapshot")); return -1; } /* disk snapshot requires at least one disk */ if (def->state == VIR_DOMAIN_SNAPSHOT_DISK_SNAPSHOT && !external) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("disk-only snapshots require at least " - "one disk to be selected for snapshot")); + _("disk-only snapshots require at least one disk to be selected for snapshot")); return -1; } @@ -786,8 +783,7 @@ qemuSnapshotPrepare(virDomainObj *vm, (def->memory == VIR_DOMAIN_SNAPSHOT_LOCATION_INTERNAL && external) || (def->memory == VIR_DOMAIN_SNAPSHOT_LOCATION_EXTERNAL && found_internal)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("mixing internal and external targets for a snapshot " - "is not yet supported")); + _("mixing internal and external targets for a snapshot is not yet supported")); return -1; } @@ -808,8 +804,7 @@ qemuSnapshotPrepare(virDomainObj *vm, found_internal && virDomainDefHasOldStyleUEFI(vm->def)) { virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("internal snapshots of a VM with pflash based " - "firmware are not supported")); + _("internal snapshots of a VM with pflash based firmware are not supported")); return -1; } @@ -1534,8 +1529,7 @@ qemuSnapshotCreateXMLValidateDef(virDomainObj *vm, (!virDomainObjIsActive(vm) || def->memory != VIR_DOMAIN_SNAPSHOT_LOCATION_EXTERNAL)) { virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("live snapshot creation is supported only " - "during full system snapshots")); + _("live snapshot creation is supported only during full system snapshots")); return -1; } @@ -1560,8 +1554,7 @@ qemuSnapshotCreateXMLValidateDef(virDomainObj *vm, case VIR_DOMAIN_SNAPSHOT_PMSUSPENDED: virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("qemu doesn't support taking snapshots of " - "PMSUSPENDED guests")); + _("qemu doesn't support taking snapshots of PMSUSPENDED guests")); return -1; /* invalid states */ @@ -1621,8 +1614,7 @@ qemuSnapshotCreateAlignDisks(virDomainObj *vm, if (virDomainObjIsActive(vm) && def->memory == VIR_DOMAIN_SNAPSHOT_LOCATION_NO) { virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("internal snapshot of a running VM " - "must include the memory state")); + _("internal snapshot of a running VM must include the memory state")); return -1; } @@ -2551,8 +2543,7 @@ qemuSnapshotRevert(virDomainObj *vm, case VIR_DOMAIN_SNAPSHOT_PMSUSPENDED: virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("qemu doesn't support reversion of snapshot taken in " - "PMSUSPENDED state")); + _("qemu doesn't support reversion of snapshot taken in PMSUSPENDED state")); goto endjob; case VIR_DOMAIN_SNAPSHOT_DISK_SNAPSHOT: diff --git a/src/qemu/qemu_tpm.c b/src/qemu/qemu_tpm.c index 450f96ecfd..bf0c6bcb0d 100644 --- a/src/qemu/qemu_tpm.c +++ b/src/qemu/qemu_tpm.c @@ -383,9 +383,7 @@ qemuTPMEmulatorRunSetup(const char *storagepath, if (!privileged && tpmversion == VIR_DOMAIN_TPM_VERSION_1_2 && !virTPMSwtpmSetupCapsGet(VIR_TPM_SWTPM_SETUP_FEATURE_TPM12_NOT_NEED_ROOT)) { return virFileWriteStr(logfile, - _("Did not create EK and certificates since " - "this requires privileged mode for a " - "TPM 1.2\n"), 0600); + _("Did not create EK and certificates since this requires privileged mode for a TPM 1.2\n"), 0600); } if (!privileged && qemuTPMCreateConfigFiles(swtpm_setup) < 0) diff --git a/src/qemu/qemu_validate.c b/src/qemu/qemu_validate.c index 797caf6076..8f9e8fd7f0 100644 --- a/src/qemu/qemu_validate.c +++ b/src/qemu/qemu_validate.c @@ -139,8 +139,7 @@ qemuValidateDomainDefFeatures(const virDomainDef *def, !virQEMUCapsSupportsVmport(qemuCaps, def)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("vmport is not available " - "with this QEMU binary")); + _("vmport is not available with this QEMU binary")); return -1; } break; @@ -149,8 +148,7 @@ qemuValidateDomainDefFeatures(const virDomainDef *def, if (def->features[i] == VIR_TRISTATE_SWITCH_ON && !virQEMUCapsGet(qemuCaps, QEMU_CAPS_DEVICE_VMCOREINFO)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("vmcoreinfo is not available " - "with this QEMU binary")); + _("vmcoreinfo is not available with this QEMU binary")); return -1; } break; @@ -828,8 +826,7 @@ qemuValidateDomainDefMemory(const virDomainDef *def, if (mem->allocation == VIR_DOMAIN_MEMORY_ALLOCATION_ONDEMAND) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("hugepages are not allowed with memory " - "allocation ondemand")); + _("hugepages are not allowed with memory allocation ondemand")); return -1; } @@ -842,8 +839,7 @@ qemuValidateDomainDefMemory(const virDomainDef *def, if (mem->source == VIR_DOMAIN_MEMORY_SOURCE_ANONYMOUS) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("hugepages are not allowed with anonymous " - "memory source")); + _("hugepages are not allowed with anonymous memory source")); return -1; } @@ -970,15 +966,13 @@ qemuValidateDomainDefPanic(const virDomainDef *def, * cannot be configured by the user */ if (!ARCH_IS_S390(def->os.arch)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("only S390 guests support " - "panic device of model 's390'")); + _("only S390 guests support panic device of model 's390'")); return -1; } if (def->panics[i]->info.type != VIR_DOMAIN_DEVICE_ADDRESS_TYPE_NONE) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("setting the panic device address is not " - "supported for model 's390'")); + _("setting the panic device address is not supported for model 's390'")); return -1; } break; @@ -989,15 +983,13 @@ qemuValidateDomainDefPanic(const virDomainDef *def, * cannot be configured by the user */ if (!ARCH_IS_X86(def->os.arch)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("only i686 and x86_64 guests support " - "panic device of model 'hyperv'")); + _("only i686 and x86_64 guests support panic device of model 'hyperv'")); return -1; } if (def->panics[i]->info.type != VIR_DOMAIN_DEVICE_ADDRESS_TYPE_NONE) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("setting the panic device address is not " - "supported for model 'hyperv'")); + _("setting the panic device address is not supported for model 'hyperv'")); return -1; } break; @@ -1008,15 +1000,13 @@ qemuValidateDomainDefPanic(const virDomainDef *def, * cannot be configured by the user */ if (!qemuDomainIsPSeries(def)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("only pSeries guests support panic device " - "of model 'pseries'")); + _("only pSeries guests support panic device of model 'pseries'")); return -1; } if (def->panics[i]->info.type != VIR_DOMAIN_DEVICE_ADDRESS_TYPE_NONE) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("setting the panic device address is not " - "supported for model 'pseries'")); + _("setting the panic device address is not supported for model 'pseries'")); return -1; } break; @@ -1024,16 +1014,14 @@ qemuValidateDomainDefPanic(const virDomainDef *def, case VIR_DOMAIN_PANIC_MODEL_ISA: if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_DEVICE_PANIC)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("the QEMU binary does not support the " - "ISA panic device")); + _("the QEMU binary does not support the ISA panic device")); return -1; } if (def->panics[i]->info.type != VIR_DOMAIN_DEVICE_ADDRESS_TYPE_NONE && def->panics[i]->info.type != VIR_DOMAIN_DEVICE_ADDRESS_TYPE_ISA) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("panic is supported only " - "with ISA address type")); + _("panic is supported only with ISA address type")); return -1; } break; @@ -1338,8 +1326,7 @@ qemuValidateDomainDef(const virDomainDef *def, case VIR_DOMAIN_LAUNCH_SECURITY_SEV: if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_SEV_GUEST)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("SEV launch security is not supported with " - "this QEMU binary")); + _("SEV launch security is not supported with this QEMU binary")); return -1; } @@ -1734,8 +1721,7 @@ qemuValidateDomainDeviceDefNetwork(const virDomainNetDef *net, } if (net->guestIP.nroutes) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Invalid attempt to set network interface " - "guest-side IP route, not supported by QEMU")); + _("Invalid attempt to set network interface guest-side IP route, not supported by QEMU")); return -1; } @@ -1751,8 +1737,7 @@ qemuValidateDomainDeviceDefNetwork(const virDomainNetDef *net, if (VIR_SOCKET_ADDR_IS_FAMILY(&ip->address, AF_INET)) { if (hasIPv4) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Only one IPv4 address per " - "interface is allowed")); + _("Only one IPv4 address per interface is allowed")); return -1; } hasIPv4 = true; @@ -1768,8 +1753,7 @@ qemuValidateDomainDeviceDefNetwork(const virDomainNetDef *net, if (VIR_SOCKET_ADDR_IS_FAMILY(&ip->address, AF_INET6)) { if (hasIPv6) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Only one IPv6 address per " - "interface is allowed")); + _("Only one IPv6 address per interface is allowed")); return -1; } hasIPv6 = true; @@ -1804,9 +1788,7 @@ qemuValidateDomainDeviceDefNetwork(const virDomainNetDef *net, } } else if (net->guestIP.nroutes || net->guestIP.nips) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Invalid attempt to set network interface " - "guest-side IP route and/or address info, " - "not supported by QEMU")); + _("Invalid attempt to set network interface guest-side IP route and/or address info, not supported by QEMU")); return -1; } @@ -2204,8 +2186,7 @@ qemuValidateDomainRNGDef(const virDomainRNGDef *def, case VIR_DOMAIN_RNG_BACKEND_RANDOM: if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_OBJECT_RNG_RANDOM)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("this qemu doesn't support the rng-random " - "backend")); + _("this qemu doesn't support the rng-random backend")); return -1; } break; @@ -2213,8 +2194,7 @@ qemuValidateDomainRNGDef(const virDomainRNGDef *def, case VIR_DOMAIN_RNG_BACKEND_EGD: if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_OBJECT_RNG_EGD)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("this qemu doesn't support the rng-egd " - "backend")); + _("this qemu doesn't support the rng-egd backend")); return -1; } @@ -2228,8 +2208,7 @@ qemuValidateDomainRNGDef(const virDomainRNGDef *def, case VIR_DOMAIN_RNG_BACKEND_BUILTIN: if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_OBJECT_RNG_BUILTIN)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("this qemu doesn't support the rng-builtin " - "backend")); + _("this qemu doesn't support the rng-builtin backend")); return -1; } break; @@ -2270,16 +2249,14 @@ qemuValidateDomainRedirdevDef(const virDomainRedirdevDef *dev, if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_USB_REDIR)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("USB redirection is not supported " - "by this version of QEMU")); + _("USB redirection is not supported by this version of QEMU")); return -1; } if (def->redirfilter && def->redirfilter->nusbdevs && !virQEMUCapsGet(qemuCaps, QEMU_CAPS_USB_REDIR_FILTER)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("USB redirection filter is not " - "supported by this version of QEMU")); + _("USB redirection filter is not supported by this version of QEMU")); return -1; } @@ -2298,8 +2275,7 @@ qemuValidateDomainWatchdogDef(const virDomainWatchdogDef *dev, if (def->nwatchdogs && def->watchdogs[0]->action != dev->action) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("watchdogs with different actions are not supported " - "with this QEMU binary")); + _("watchdogs with different actions are not supported with this QEMU binary")); return -1; } @@ -2379,17 +2355,14 @@ qemuValidateDomainMdevDefVFIOPCI(const virDomainHostdevDef *hostdev, if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_DEVICE_VFIO_PCI)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("VFIO PCI device assignment is not " - "supported by this version of QEMU")); + _("VFIO PCI device assignment is not supported by this version of QEMU")); return -1; } /* VFIO-PCI does not support boot */ if (hostdev->info->bootIndex) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("booting from assigned devices is not " - "supported by mediated devices of " - "model vfio-pci")); + _("booting from assigned devices is not supported by mediated devices of model vfio-pci")); return -1; } @@ -2399,15 +2372,13 @@ qemuValidateDomainMdevDefVFIOPCI(const virDomainHostdevDef *hostdev, if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_VFIO_PCI_DISPLAY)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("display property of device vfio-pci is " - "not supported by this version of QEMU")); + _("display property of device vfio-pci is not supported by this version of QEMU")); return -1; } if (dev->model != VIR_MDEV_MODEL_TYPE_VFIO_PCI) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("<hostdev> attribute 'display' is only supported" - " with model='vfio-pci'")); + _("<hostdev> attribute 'display' is only supported with model='vfio-pci'")); return -1; } @@ -2415,8 +2386,7 @@ qemuValidateDomainMdevDefVFIOPCI(const virDomainHostdevDef *hostdev, if (dev->display == VIR_TRISTATE_SWITCH_ON) { if (def->ngraphics == 0) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("graphics device is needed for attribute value " - "'display=on' in <hostdev>")); + _("graphics device is needed for attribute value 'display=on' in <hostdev>")); return -1; } } @@ -2435,17 +2405,14 @@ qemuValidateDomainMdevDefVFIOAP(const virDomainHostdevDef *hostdev, if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_DEVICE_VFIO_AP)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("VFIO AP device assignment is not " - "supported by this version of QEMU")); + _("VFIO AP device assignment is not supported by this version of QEMU")); return -1; } /* VFIO-AP does not support boot */ if (hostdev->info->bootIndex) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("booting from assigned devices is not " - "supported by mediated devices of " - "model vfio-ap")); + _("booting from assigned devices is not supported by mediated devices of model vfio-ap")); return -1; } @@ -2457,8 +2424,7 @@ qemuValidateDomainMdevDefVFIOAP(const virDomainHostdevDef *hostdev, hdev->source.subsys.u.mdev.model == VIR_MDEV_MODEL_TYPE_VFIO_AP) { if (vfioap_found) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Only one hostdev of model vfio-ap is " - "supported")); + _("Only one hostdev of model vfio-ap is supported")); return -1; } vfioap_found = true; @@ -2485,8 +2451,7 @@ qemuValidateDomainMdevDef(const virDomainHostdevDef *hostdev, case VIR_MDEV_MODEL_TYPE_VFIO_CCW: if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_DEVICE_VFIO_CCW)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("VFIO CCW device assignment is not " - "supported by this version of QEMU")); + _("VFIO CCW device assignment is not supported by this version of QEMU")); return -1; } break; @@ -2536,16 +2501,14 @@ qemuValidateDomainDeviceDefHostdev(const virDomainHostdevDef *hostdev, if (backend == VIR_DOMAIN_HOSTDEV_PCI_BACKEND_VFIO) { if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_DEVICE_VFIO_PCI)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("VFIO PCI device assignment is not " - "supported by this version of qemu")); + _("VFIO PCI device assignment is not supported by this version of qemu")); return -1; } } if (hostdev->writeFiltering != VIR_TRISTATE_BOOL_ABSENT) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Write filtering of PCI device configuration " - "space is not supported by qemu")); + _("Write filtering of PCI device configuration space is not supported by qemu")); return -1; } break; @@ -2553,8 +2516,7 @@ qemuValidateDomainDeviceDefHostdev(const virDomainHostdevDef *hostdev, case VIR_DOMAIN_HOSTDEV_SUBSYS_TYPE_SCSI_HOST: if (hostdev->info->bootIndex) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("booting from assigned devices is not " - "supported by vhost SCSI devices")); + _("booting from assigned devices is not supported by vhost SCSI devices")); return -1; } @@ -2639,8 +2601,7 @@ qemuValidateDomainDeviceDefVideo(const virDomainVideoDef *video, if (video->vgamem) { if (video->vgamem < 1024) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("value for 'vgamem' must be at least 1 MiB " - "(1024 KiB)")); + _("value for 'vgamem' must be at least 1 MiB (1024 KiB)")); return -1; } @@ -2666,9 +2627,8 @@ qemuValidateDomainDeviceDefVideo(const virDomainVideoDef *video, if (video->type == VIR_DOMAIN_VIDEO_TYPE_VGA || video->type == VIR_DOMAIN_VIDEO_TYPE_VMVGA) { if (video->vram && video->vram < 1024) { - virReportError(VIR_ERR_CONFIG_UNSUPPORTED, - "%s", _("value for 'vram' must be at least " - "1 MiB (1024 KiB)")); + virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", + _("value for 'vram' must be at least 1 MiB (1024 KiB)")); return -1; } } @@ -2867,8 +2827,7 @@ qemuValidateDomainDeviceDefDiskFrontend(const virDomainDiskDef *disk, if (disk->bus == VIR_DOMAIN_DISK_BUS_SCSI && !virQEMUCapsGet(qemuCaps, QEMU_CAPS_SCSI_BLOCK)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("This QEMU doesn't support scsi-block for " - "lun passthrough")); + _("This QEMU doesn't support scsi-block for lun passthrough")); return -1; } @@ -2887,8 +2846,7 @@ qemuValidateDomainDeviceDefDiskFrontend(const virDomainDiskDef *disk, } if (disk->vendor || disk->product) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Setting vendor or product is not supported " - "for lun device")); + _("Setting vendor or product is not supported for lun device")); return -1; } } @@ -2960,8 +2918,7 @@ qemuValidateDomainDeviceDefDiskFrontend(const virDomainDiskDef *disk, case VIR_DOMAIN_DISK_BUS_USB: if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_DEVICE_USB_STORAGE)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("This QEMU doesn't support '-device " - "usb-storage'")); + _("This QEMU doesn't support '-device usb-storage'")); return -1; } @@ -3025,8 +2982,7 @@ qemuValidateDomainDeviceDefDiskFrontend(const virDomainDiskDef *disk, disk->bus == VIR_DOMAIN_DISK_BUS_SCSI && disk->device == VIR_DOMAIN_DISK_DEVICE_LUN) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("scsi-block 'lun' devices do not support the " - "serial property")); + _("scsi-block 'lun' devices do not support the serial property")); return -1; } @@ -3056,8 +3012,7 @@ qemuValidateDomainDeviceDefDiskBlkdeviotune(const virDomainDiskDef *disk, if (disk->blkdeviotune.group_name && !virDomainBlockIoTuneInfoHasAny(&disk->blkdeviotune)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("group_name can be configured only together with " - "settings")); + _("group_name can be configured only together with settings")); return -1; } @@ -3285,8 +3240,7 @@ qemuValidateCheckSCSIControllerModel(virQEMUCaps *qemuCaps, case VIR_DOMAIN_CONTROLLER_MODEL_SCSI_LSILOGIC: if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_SCSI_LSI)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("This QEMU doesn't support " - "the LSI 53C895A SCSI controller")); + _("This QEMU doesn't support the LSI 53C895A SCSI controller")); return false; } break; @@ -3295,8 +3249,7 @@ qemuValidateCheckSCSIControllerModel(virQEMUCaps *qemuCaps, case VIR_DOMAIN_CONTROLLER_MODEL_SCSI_VIRTIO_NON_TRANSITIONAL: if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_VIRTIO_SCSI)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("This QEMU doesn't support " - "virtio scsi controller")); + _("This QEMU doesn't support virtio scsi controller")); return false; } break; @@ -3306,24 +3259,21 @@ qemuValidateCheckSCSIControllerModel(virQEMUCaps *qemuCaps, case VIR_DOMAIN_CONTROLLER_MODEL_SCSI_LSISAS1068: if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_SCSI_MPTSAS1068)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("This QEMU doesn't support " - "the LSI SAS1068 (MPT Fusion) controller")); + _("This QEMU doesn't support the LSI SAS1068 (MPT Fusion) controller")); return false; } break; case VIR_DOMAIN_CONTROLLER_MODEL_SCSI_LSISAS1078: if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_SCSI_MEGASAS)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("This QEMU doesn't support " - "the LSI SAS1078 (MegaRAID) controller")); + _("This QEMU doesn't support the LSI SAS1078 (MegaRAID) controller")); return false; } break; case VIR_DOMAIN_CONTROLLER_MODEL_SCSI_VMPVSCSI: if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_SCSI_PVSCSI)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("This QEMU doesn't support " - "the pvscsi (VMware paravirtual SCSI) controller")); + _("This QEMU doesn't support the pvscsi (VMware paravirtual SCSI) controller")); return false; } break; @@ -3336,22 +3286,19 @@ qemuValidateCheckSCSIControllerModel(virQEMUCaps *qemuCaps, case VIR_DOMAIN_CONTROLLER_MODEL_SCSI_NCR53C90: if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_SCSI_NCR53C90)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("This QEMU doesn't support " - "the NCR53C90 (ESP) controller")); + _("This QEMU doesn't support the NCR53C90 (ESP) controller")); } return true; case VIR_DOMAIN_CONTROLLER_MODEL_SCSI_DC390: if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_SCSI_DC390)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("This QEMU doesn't support " - "the DC390 (ESP) controller")); + _("This QEMU doesn't support the DC390 (ESP) controller")); } return true; case VIR_DOMAIN_CONTROLLER_MODEL_SCSI_AM53C974: if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_SCSI_AM53C974)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("This QEMU doesn't support " - "the AM53C974 (ESP) controller")); + _("This QEMU doesn't support the AM53C974 (ESP) controller")); } return true; case VIR_DOMAIN_CONTROLLER_MODEL_SCSI_DEFAULT: @@ -3401,12 +3348,10 @@ qemuValidateDomainDeviceDefControllerIDE(const virDomainControllerDef *controlle */ if (qemuDomainHasBuiltinIDE(def)) virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Only a single IDE controller is supported " - "for this machine type")); + _("Only a single IDE controller is supported for this machine type")); else virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("IDE controllers are unsupported for " - "this QEMU binary or machine type")); + _("IDE controllers are unsupported for this QEMU binary or machine type")); return -1; } @@ -3432,8 +3377,7 @@ qemuValidateCheckSCSIControllerIOThreads(const virDomainControllerDef *controlle controller->info.type != VIR_DOMAIN_DEVICE_ADDRESS_TYPE_PCI && controller->info.type != VIR_DOMAIN_DEVICE_ADDRESS_TYPE_CCW) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("virtio-scsi IOThreads only available for virtio " - "pci and virtio ccw controllers")); + _("virtio-scsi IOThreads only available for virtio pci and virtio ccw controllers")); return false; } @@ -4154,8 +4098,7 @@ qemuValidateDomainDeviceDefSPICEGraphics(const virDomainGraphicsDef *graphics, case VIR_DOMAIN_GRAPHICS_LISTEN_TYPE_NETWORK: if (tlsPort > 0 && !cfg->spiceTLS) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("spice TLS port set in XML configuration, " - "but TLS is disabled in qemu.conf")); + _("spice TLS port set in XML configuration, but TLS is disabled in qemu.conf")); return -1; } break; @@ -4262,8 +4205,7 @@ qemuValidateDomainDeviceDefGraphics(const virDomainGraphicsDef *graphics, graphics->type != VIR_DOMAIN_GRAPHICS_TYPE_VNC && graphics->type != VIR_DOMAIN_GRAPHICS_TYPE_SPICE) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("graphics type 'egl-headless' is only supported " - "with one of: 'vnc', 'spice' graphics types")); + _("graphics type 'egl-headless' is only supported with one of: 'vnc', 'spice' graphics types")); return -1; } @@ -4273,8 +4215,7 @@ qemuValidateDomainDeviceDefGraphics(const virDomainGraphicsDef *graphics, if (graphics->type == VIR_DOMAIN_GRAPHICS_TYPE_SPICE && graphics->data.spice.gl == VIR_TRISTATE_BOOL_YES) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("multiple OpenGL displays are not supported " - "by QEMU")); + _("multiple OpenGL displays are not supported by QEMU")); return -1; } } @@ -4291,8 +4232,7 @@ qemuValidateDomainDeviceDefGraphics(const virDomainGraphicsDef *graphics, if (graphics->data.egl_headless.rendernode && !virQEMUCapsGet(qemuCaps, QEMU_CAPS_EGL_HEADLESS_RENDERNODE)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("This QEMU doesn't support OpenGL rendernode " - "with egl-headless graphics type")); + _("This QEMU doesn't support OpenGL rendernode with egl-headless graphics type")); return -1; } @@ -4555,16 +4495,14 @@ qemuValidateDomainDeviceDefSound(virDomainSoundDef *sound, case VIR_DOMAIN_SOUND_MODEL_USB: if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_OBJECT_USB_AUDIO)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("usb-audio controller is not supported " - "by this QEMU binary")); + _("usb-audio controller is not supported by this QEMU binary")); return -1; } break; case VIR_DOMAIN_SOUND_MODEL_ICH9: if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_DEVICE_ICH9_INTEL_HDA)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("The ich9-intel-hda audio controller " - "is not supported in this QEMU binary")); + _("The ich9-intel-hda audio controller is not supported in this QEMU binary")); return -1; } break; @@ -4609,8 +4547,7 @@ qemuValidateDomainDeviceDefVsock(virQEMUCaps *qemuCaps) { if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_DEVICE_VHOST_VSOCK)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("vsock device is not supported " - "with this QEMU binary")); + _("vsock device is not supported with this QEMU binary")); return -1; } @@ -4716,8 +4653,7 @@ qemuValidateDomainDeviceDefInput(const virDomainInputDef *input, input->type == VIR_DOMAIN_INPUT_TYPE_KBD && !virQEMUCapsGet(qemuCaps, QEMU_CAPS_DEVICE_USB_KBD)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("usb keyboard is not supported by this " - "QEMU binary")); + _("usb keyboard is not supported by this QEMU binary")); return -1; } @@ -4904,36 +4840,31 @@ qemuValidateDomainDeviceDefIOMMU(const virDomainIOMMUDef *iommu, if (iommu->intremap != VIR_TRISTATE_SWITCH_ABSENT && !virQEMUCapsGet(qemuCaps, QEMU_CAPS_INTEL_IOMMU_INTREMAP)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("iommu: interrupt remapping is not supported " - "with this QEMU binary")); + _("iommu: interrupt remapping is not supported with this QEMU binary")); return -1; } if (iommu->caching_mode != VIR_TRISTATE_SWITCH_ABSENT && !virQEMUCapsGet(qemuCaps, QEMU_CAPS_INTEL_IOMMU_CACHING_MODE)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("iommu: caching mode is not supported " - "with this QEMU binary")); + _("iommu: caching mode is not supported with this QEMU binary")); return -1; } if (iommu->eim != VIR_TRISTATE_SWITCH_ABSENT && !virQEMUCapsGet(qemuCaps, QEMU_CAPS_INTEL_IOMMU_EIM)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("iommu: eim is not supported " - "with this QEMU binary")); + _("iommu: eim is not supported with this QEMU binary")); return -1; } if (iommu->iotlb != VIR_TRISTATE_SWITCH_ABSENT && !virQEMUCapsGet(qemuCaps, QEMU_CAPS_INTEL_IOMMU_DEVICE_IOTLB)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("iommu: device IOTLB is not supported " - "with this QEMU binary")); + _("iommu: device IOTLB is not supported with this QEMU binary")); return -1; } if (iommu->aw_bits > 0 && !virQEMUCapsGet(qemuCaps, QEMU_CAPS_INTEL_IOMMU_AW_BITS)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("iommu: aw_bits is not supported " - "with this QEMU binary")); + _("iommu: aw_bits is not supported with this QEMU binary")); return -1; } @@ -4952,8 +4883,7 @@ qemuValidateDomainDeviceDefNVRAM(virDomainNVRAMDef *nvram, if (qemuDomainIsPSeries(def)) { if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_DEVICE_NVRAM)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("nvram device is not supported by " - "this QEMU binary")); + _("nvram device is not supported by this QEMU binary")); return -1; } } else { @@ -5021,8 +4951,7 @@ qemuValidateDomainDeviceDefMemory(virDomainMemoryDef *mem, if (mem->target.nvdimm.readonly && !virQEMUCapsGet(qemuCaps, QEMU_CAPS_DEVICE_NVDIMM_UNARMED)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("nvdimm readonly property is not available " - "with this QEMU binary")); + _("nvdimm readonly property is not available with this QEMU binary")); return -1; } break; -- 2.41.0

Error messages are exempt from the 80 columns rule. Move them onto one line. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/remote/remote_daemon.c | 3 +-- src/remote/remote_driver.c | 27 +++++++++------------------ src/remote/remote_sockets.c | 3 +-- 3 files changed, 11 insertions(+), 22 deletions(-) diff --git a/src/remote/remote_daemon.c b/src/remote/remote_daemon.c index d4d999e53a..657c053f6f 100644 --- a/src/remote/remote_daemon.c +++ b/src/remote/remote_daemon.c @@ -219,8 +219,7 @@ daemonSetupNetworking(virNetServer *srv, #ifdef WITH_IP # ifdef LIBVIRTD if (act && ipsock) { - VIR_ERROR(_("--listen parameter not permitted with systemd activation " - "sockets, see 'man libvirtd' for further guidance")); + VIR_ERROR(_("--listen parameter not permitted with systemd activation sockets, see 'man libvirtd' for further guidance")); return -1; } # else /* ! LIBVIRTD */ diff --git a/src/remote/remote_driver.c b/src/remote/remote_driver.c index faad7292ed..2f8c9800a7 100644 --- a/src/remote/remote_driver.c +++ b/src/remote/remote_driver.c @@ -1103,8 +1103,7 @@ doRemoteOpen(virConnectPtr conn, case REMOTE_DRIVER_TRANSPORT_SSH: case REMOTE_DRIVER_TRANSPORT_EXT: virReportError(VIR_ERR_INVALID_ARG, "%s", - _("transport methods unix, ssh and ext are not supported " - "under Windows")); + _("transport methods unix, ssh and ext are not supported under Windows")); goto error; #endif /* WIN32 */ @@ -1478,8 +1477,7 @@ remoteNodeGetCPUStats(virConnectPtr conn, if (ret.params.params_len > REMOTE_NODE_CPU_STATS_MAX || ret.params.params_len > *nparams) { virReportError(VIR_ERR_RPC, "%s", - _("remoteNodeGetCPUStats: " - "returned number of stats exceeds limit")); + _("remoteNodeGetCPUStats: returned number of stats exceeds limit")); goto cleanup; } /* Handle the case when the caller does not know the number of stats @@ -1538,8 +1536,7 @@ remoteNodeGetMemoryStats(virConnectPtr conn, if (ret.params.params_len > REMOTE_NODE_MEMORY_STATS_MAX || ret.params.params_len > *nparams) { virReportError(VIR_ERR_RPC, "%s", - _("remoteNodeGetMemoryStats: " - "returned number of stats exceeds limit")); + _("remoteNodeGetMemoryStats: returned number of stats exceeds limit")); goto cleanup; } /* Handle the case when the caller does not know the number of stats @@ -1703,8 +1700,7 @@ remoteDomainBlockStatsFlags(virDomainPtr domain, if (ret.params.params_len > REMOTE_DOMAIN_BLOCK_STATS_PARAMETERS_MAX || ret.params.params_len > *nparams) { virReportError(VIR_ERR_RPC, "%s", - _("remoteDomainBlockStatsFlags: " - "returned number of stats exceeds limit")); + _("remoteDomainBlockStatsFlags: returned number of stats exceeds limit")); goto cleanup; } @@ -2760,8 +2756,7 @@ static int remoteDomainGetCPUStats(virDomainPtr domain, (ret.params.params_len && ((ret.params.params_len % ret.nparams) || ret.nparams > nparams))) { virReportError(VIR_ERR_RPC, "%s", - _("remoteDomainGetCPUStats: " - "returned number of stats exceeds limit")); + _("remoteDomainGetCPUStats: returned number of stats exceeds limit")); memset(params, 0, sizeof(*params) * nparams * ncpus); goto cleanup; } @@ -6114,8 +6109,7 @@ remoteConnectSetKeepAlive(virConnectPtr conn, int interval, unsigned int count) if (!virNetClientKeepAliveIsSupported(priv->client)) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("the caller doesn't support keepalive protocol;" - " perhaps it's missing event loop implementation")); + _("the caller doesn't support keepalive protocol; perhaps it's missing event loop implementation")); return -1; } @@ -7562,8 +7556,7 @@ remoteDomainAuthorizedSSHKeysGet(virDomainPtr domain, if (ret.keys.keys_len > REMOTE_DOMAIN_AUTHORIZED_SSH_KEYS_MAX) { virReportError(VIR_ERR_RPC, "%s", - _("remoteDomainAuthorizedSSHKeysGet: " - "returned number of keys exceeds limit")); + _("remoteDomainAuthorizedSSHKeysGet: returned number of keys exceeds limit")); goto cleanup; } @@ -7592,8 +7585,7 @@ remoteDomainAuthorizedSSHKeysSet(virDomainPtr domain, if (nkeys > REMOTE_DOMAIN_AUTHORIZED_SSH_KEYS_MAX) { virReportError(VIR_ERR_RPC, "%s", - _("remoteDomainAuthorizedSSHKeysSet: " - "returned number of keys exceeds limit")); + _("remoteDomainAuthorizedSSHKeysSet: returned number of keys exceeds limit")); return -1; } @@ -7635,8 +7627,7 @@ remoteDomainGetMessages(virDomainPtr domain, if (ret.msgs.msgs_len > REMOTE_DOMAIN_MESSAGES_MAX) { virReportError(VIR_ERR_RPC, "%s", - _("remoteDomainGetMessages: " - "returned number of msgs exceeds limit")); + _("remoteDomainGetMessages: returned number of msgs exceeds limit")); goto cleanup; } diff --git a/src/remote/remote_sockets.c b/src/remote/remote_sockets.c index 9c1944209f..4ab3d72933 100644 --- a/src/remote/remote_sockets.c +++ b/src/remote/remote_sockets.c @@ -96,8 +96,7 @@ remoteSplitURIScheme(virURI *uri, if ((val = remoteDriverTransportTypeFromString(tmp)) < 0) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("remote_open: transport in URL not recognised " - "(should be tls|unix|ssh|ext|tcp|libssh2|libssh)")); + _("remote_open: transport in URL not recognised (should be tls|unix|ssh|ext|tcp|libssh2|libssh)")); return -1; } -- 2.41.0

Error messages are exempt from the 80 columns rule. Move them onto one line. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/rpc/virnetclient.c | 9 +++---- src/rpc/virnetlibsshsession.c | 28 +++++++--------------- src/rpc/virnetserver.c | 9 +++---- src/rpc/virnetserverclient.c | 3 +-- src/rpc/virnetsshsession.c | 45 ++++++++++++----------------------- src/rpc/virnettlscontext.c | 6 +---- 6 files changed, 32 insertions(+), 68 deletions(-) diff --git a/src/rpc/virnetclient.c b/src/rpc/virnetclient.c index 18f87653f5..4ab8af68c5 100644 --- a/src/rpc/virnetclient.c +++ b/src/rpc/virnetclient.c @@ -1011,8 +1011,7 @@ int virNetClientSetTLSSession(virNetClient *client, } if (len != 1 || buf[0] != '\1') { virReportError(VIR_ERR_RPC, "%s", - _("server verification (of our certificate or IP " - "address) failed")); + _("server verification (of our certificate or IP address) failed")); goto error; } @@ -2069,15 +2068,13 @@ virNetClientCallNew(virNetMessage *msg, (msg->bufferLength != 0) && (msg->header.status == VIR_NET_CONTINUE)) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Attempt to send an asynchronous message with" - " a synchronous reply")); + _("Attempt to send an asynchronous message with a synchronous reply")); goto error; } if (expectReply && nonBlock) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Attempt to send a non-blocking message with" - " a synchronous reply")); + _("Attempt to send a non-blocking message with a synchronous reply")); goto error; } diff --git a/src/rpc/virnetlibsshsession.c b/src/rpc/virnetlibsshsession.c index 8cb57e857f..6632e4a9ef 100644 --- a/src/rpc/virnetlibsshsession.c +++ b/src/rpc/virnetlibsshsession.c @@ -195,8 +195,7 @@ virLibsshServerKeyAsString(virNetLibsshSession *sess) if (ssh_get_server_publickey(sess->session, &key) != SSH_OK) { virReportError(VIR_ERR_LIBSSH, "%s", - _("failed to get the key of the current " - "session")); + _("failed to get the key of the current session")); return NULL; } @@ -261,8 +260,7 @@ virNetLibsshCheckHostKey(virNetLibsshSession *sess) /* host key verification failed */ virReportError(VIR_ERR_AUTH_FAILED, - _("!!! SSH HOST KEY VERIFICATION FAILED !!!: Identity of host '%1$s:%2$d' differs from stored identity. " - "Please verify the new host key '%3$s' to avoid possible man in the middle attack. The key is stored in '%4$s'."), + _("!!! SSH HOST KEY VERIFICATION FAILED !!!: Identity of host '%1$s:%2$d' differs from stored identity. Please verify the new host key '%3$s' to avoid possible man in the middle attack. The key is stored in '%4$s'."), sess->hostname, sess->port, keyhashstr, sess->knownHostsFile); @@ -279,8 +277,7 @@ virNetLibsshCheckHostKey(virNetLibsshSession *sess) /* ask to add the key */ if (!sess->cred || !sess->cred->cb) { virReportError(VIR_ERR_LIBSSH, "%s", - _("No user interaction callback provided: " - "Can't verify the session host key")); + _("No user interaction callback provided: Can't verify the session host key")); return -1; } @@ -355,8 +352,7 @@ virNetLibsshAuthenticatePrivkeyCb(const char *prompt, /* request user's key password */ if (!sess->cred || !sess->cred->cb) { virReportError(VIR_ERR_LIBSSH, "%s", - _("No user interaction callback provided: " - "Can't retrieve private key passphrase")); + _("No user interaction callback provided: Can't retrieve private key passphrase")); return -1; } @@ -505,8 +501,7 @@ virNetLibsshAuthenticatePassword(virNetLibsshSession *sess) /* password authentication with interactive password request */ if (!sess->cred || !sess->cred->cb) { virReportError(VIR_ERR_LIBSSH, "%s", - _("Can't perform authentication: " - "Authentication callback not provided")); + _("Can't perform authentication: Authentication callback not provided")); return SSH_AUTH_ERROR; } @@ -567,9 +562,7 @@ virNetLibsshAuthenticateKeyboardInteractive(virNetLibsshSession *sess, /* request user's key password */ if (!sess->cred || !sess->cred->cb) { virReportError(VIR_ERR_LIBSSH, "%s", - _("No user interaction callback provided: " - "Can't get input from keyboard interactive " - "authentication")); + _("No user interaction callback provided: Can't get input from keyboard interactive authentication")); return SSH_AUTH_ERROR; } @@ -738,12 +731,10 @@ virNetLibsshAuthenticate(virNetLibsshSession *sess) errmsg); } else if (no_method && !auth_failed) { virReportError(VIR_ERR_AUTH_FAILED, "%s", - _("None of the requested authentication methods " - "are supported by the server")); + _("None of the requested authentication methods are supported by the server")); } else { virReportError(VIR_ERR_AUTH_FAILED, "%s", - _("All provided authentication methods with credentials " - "were rejected by the server")); + _("All provided authentication methods with credentials were rejected by the server")); } return -1; @@ -803,8 +794,7 @@ virNetLibsshValidateConfig(virNetLibsshSession *sess) } if (!has_auths) { virReportError(VIR_ERR_LIBSSH, "%s", - _("No authentication methods and credentials " - "provided")); + _("No authentication methods and credentials provided")); return -1; } diff --git a/src/rpc/virnetserver.c b/src/rpc/virnetserver.c index 7233629f22..770476c1a6 100644 --- a/src/rpc/virnetserver.c +++ b/src/rpc/virnetserver.c @@ -372,8 +372,7 @@ virNetServerNew(const char *name, if (max_clients < max_anonymous_clients) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("The overall maximum number of clients must not be less " - "than the number of clients waiting for authentication")); + _("The overall maximum number of clients must not be less than the number of clients waiting for authentication")); return NULL; } @@ -458,8 +457,7 @@ virNetServerNewPostExecRestart(virJSONValue *object, } if (max_clients < max_anonymous_clients) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("The overall maximum number of clients must not be less " - "than the number of clients waiting for authentication")); + _("The overall maximum number of clients must not be less than the number of clients waiting for authentication")); return NULL; } } else { @@ -1127,8 +1125,7 @@ virNetServerSetClientLimits(virNetServer *srv, if (max < max_unauth) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("The overall maximum number of clients must not be less " - "than the number of clients waiting for authentication")); + _("The overall maximum number of clients must not be less than the number of clients waiting for authentication")); return -1; } diff --git a/src/rpc/virnetserverclient.c b/src/rpc/virnetserverclient.c index c0c018b6be..355aab4b04 100644 --- a/src/rpc/virnetserverclient.c +++ b/src/rpc/virnetserverclient.c @@ -531,8 +531,7 @@ virNetServerClient *virNetServerClientNewPostExecRestart(virNetServer *srv, } else { if (virJSONValueObjectGetNumberLong(object, "conn_time", ×tamp) < 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Malformed conn_time field in JSON " - "state document")); + _("Malformed conn_time field in JSON state document")); return NULL; } } diff --git a/src/rpc/virnetsshsession.c b/src/rpc/virnetsshsession.c index 16d420467e..316521d4cf 100644 --- a/src/rpc/virnetsshsession.c +++ b/src/rpc/virnetsshsession.c @@ -307,8 +307,7 @@ virNetSSHCheckHostKey(virNetSSHSession *sess) /* ask to add the key */ if (!sess->cred || !sess->cred->cb) { virReportError(VIR_ERR_SSH, "%s", - _("No user interaction callback provided: " - "Can't verify the session host key")); + _("No user interaction callback provided: Can't verify the session host key")); return -1; } @@ -320,8 +319,7 @@ virNetSSHCheckHostKey(virNetSSHSession *sess) if (i == sess->cred->ncredtype) { virReportError(VIR_ERR_SSH, "%s", - _("no suitable callback for host key " - "verification")); + _("no suitable callback for host key verification")); return -1; } @@ -348,8 +346,7 @@ virNetSSHCheckHostKey(virNetSSHSession *sess) if (sess->cred->cb(&askKey, 1, sess->cred->cbdata)) { virReportError(VIR_ERR_SSH, "%s", - _("failed to retrieve decision to accept " - "host key")); + _("failed to retrieve decision to accept host key")); tmp = (char*)askKey.prompt; VIR_FREE(tmp); VIR_FREE(keyhashstr); @@ -455,8 +452,7 @@ virNetSSHCheckHostKey(virNetSSHSession *sess) case LIBSSH2_KNOWNHOST_CHECK_MISMATCH: /* host key verification failed */ virReportError(VIR_ERR_AUTH_FAILED, - _("!!! SSH HOST KEY VERIFICATION FAILED !!!: Identity of host '%1$s:%2$d' differs from stored identity. " - "Please verify the new host key '%3$s' to avoid possible man in the middle attack. The key is stored in '%4$s'."), + _("!!! SSH HOST KEY VERIFICATION FAILED !!!: Identity of host '%1$s:%2$d' differs from stored identity. Please verify the new host key '%3$s' to avoid possible man in the middle attack. The key is stored in '%4$s'."), sess->hostname, sess->port, knownHostEntry->key, sess->knownHostsFile); return -1; @@ -532,12 +528,10 @@ virNetSSHAuthenticateAgent(virNetSSHSession *sess) if (ret == 1) { if (no_identity) { virReportError(VIR_ERR_AUTH_FAILED, "%s", - _("SSH Agent did not provide any " - "authentication identity")); + _("SSH Agent did not provide any authentication identity")); } else { virReportError(VIR_ERR_AUTH_FAILED, "%s", - _("All identities provided by the SSH Agent " - "were rejected")); + _("All identities provided by the SSH Agent were rejected")); } return 1; } @@ -589,8 +583,7 @@ virNetSSHAuthenticatePrivkey(virNetSSHSession *sess, /* request user's key password */ if (!sess->cred || !sess->cred->cb) { virReportError(VIR_ERR_SSH, "%s", - _("No user interaction callback provided: " - "Can't retrieve private key passphrase")); + _("No user interaction callback provided: Can't retrieve private key passphrase")); return -1; } @@ -615,8 +608,7 @@ virNetSSHAuthenticatePrivkey(virNetSSHSession *sess, if (sess->cred->cb(&retr_passphrase, 1, sess->cred->cbdata)) { virReportError(VIR_ERR_SSH, "%s", - _("failed to retrieve private key passphrase: " - "callback has failed")); + _("failed to retrieve private key passphrase: callback has failed")); tmp = (char *)retr_passphrase.prompt; VIR_FREE(tmp); return -1; @@ -671,8 +663,7 @@ virNetSSHAuthenticatePassword(virNetSSHSession *sess) /* password authentication with interactive password request */ if (!sess->cred || !sess->cred->cb) { virReportError(VIR_ERR_SSH, "%s", - _("Can't perform authentication: " - "Authentication callback not provided")); + _("Can't perform authentication: Authentication callback not provided")); goto cleanup; } @@ -732,8 +723,7 @@ virNetSSHAuthenticateKeyboardInteractive(virNetSSHSession *sess, if (!sess->cred || !sess->cred->cb) { virReportError(VIR_ERR_SSH, "%s", - _("Can't perform keyboard-interactive authentication: " - "Authentication callback not provided")); + _("Can't perform keyboard-interactive authentication: Authentication callback not provided")); return -1; } @@ -748,8 +738,7 @@ virNetSSHAuthenticateKeyboardInteractive(virNetSSHSession *sess, switch (sess->authCbErr) { case VIR_NET_SSH_AUTHCB_NO_METHOD: virReportError(VIR_ERR_SSH, "%s", - _("no suitable method to retrieve " - "authentication credentials")); + _("no suitable method to retrieve authentication credentials")); return -1; case VIR_NET_SSH_AUTHCB_OOM: /* OOM error already reported */ @@ -801,8 +790,7 @@ virNetSSHAuthenticate(virNetSSHSession *sess) if (!sess->nauths) { virReportError(VIR_ERR_SSH, "%s", - _("No authentication methods and credentials " - "provided")); + _("No authentication methods and credentials provided")); return -1; } @@ -866,12 +854,10 @@ virNetSSHAuthenticate(virNetSSHSession *sess) /* pass through the error */ } else if (no_method && !auth_failed) { virReportError(VIR_ERR_AUTH_FAILED, "%s", - _("None of the requested authentication methods " - "are supported by the server")); + _("None of the requested authentication methods are supported by the server")); } else { virReportError(VIR_ERR_AUTH_FAILED, "%s", - _("All provided authentication methods with credentials " - "were rejected by the server")); + _("All provided authentication methods with credentials were rejected by the server")); } return -1; @@ -914,8 +900,7 @@ virNetSSHValidateConfig(virNetSSHSession *sess) { if (sess->nauths == 0) { virReportError(VIR_ERR_SSH, "%s", - _("No authentication methods and credentials " - "provided")); + _("No authentication methods and credentials provided")); return -1; } diff --git a/src/rpc/virnettlscontext.c b/src/rpc/virnettlscontext.c index 1939fe5d6e..dc60244927 100644 --- a/src/rpc/virnettlscontext.c +++ b/src/rpc/virnettlscontext.c @@ -366,11 +366,7 @@ virNetTLSContextCheckCertDNACL(const char *dname, /* This is the most common error: make it informative. */ virReportError(VIR_ERR_SYSTEM_ERROR, "%s", - _("Client's Distinguished Name is not on the list " - "of allowed clients (tls_allowed_dn_list). Use " - "'virt-pki-query-dn clientcert.pem' to view the " - "Distinguished Name field in the client certificate, " - "or run this daemon with --verbose option.")); + _("Client's Distinguished Name is not on the list of allowed clients (tls_allowed_dn_list). Use 'virt-pki-query-dn clientcert.pem' to view the Distinguished Name field in the client certificate, or run this daemon with --verbose option.")); return 0; } -- 2.41.0

Error messages are exempt from the 80 columns rule. Move them onto one line. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/security/security_dac.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/security/security_dac.c b/src/security/security_dac.c index 20e0998fbc..4667328b26 100644 --- a/src/security/security_dac.c +++ b/src/security/security_dac.c @@ -2320,8 +2320,7 @@ virSecurityDACGenLabel(virSecurityManager *mgr, if (seclabel->imagelabel) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("security image label already " - "defined for VM")); + _("security image label already defined for VM")); return rc; } -- 2.41.0

Error messages are exempt from the 80 columns rule. Move them onto one line. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/storage/storage_backend_disk.c | 3 +- src/storage/storage_backend_fs.c | 3 +- src/storage/storage_backend_zfs.c | 3 +- src/storage/storage_driver.c | 21 +++++-------- src/storage/storage_util.c | 48 ++++++++++-------------------- 5 files changed, 26 insertions(+), 52 deletions(-) diff --git a/src/storage/storage_backend_disk.c b/src/storage/storage_backend_disk.c index 7466f0e234..996395de4a 100644 --- a/src/storage/storage_backend_disk.c +++ b/src/storage/storage_backend_disk.c @@ -659,8 +659,7 @@ virStorageBackendDiskPartFormat(virStoragePoolObj *pool, *partFormat = g_strdup_printf("logical %s", partedFormat); } else { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("no extended partition found and no " - "primary partition available")); + _("no extended partition found and no primary partition available")); return -1; } break; diff --git a/src/storage/storage_backend_fs.c b/src/storage/storage_backend_fs.c index a80d228201..1851704d21 100644 --- a/src/storage/storage_backend_fs.c +++ b/src/storage/storage_backend_fs.c @@ -219,8 +219,7 @@ virStorageBackendFileSystemIsValid(virStoragePoolObj *pool) _("missing source device")); else virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("expected exactly 1 device for the " - "storage pool")); + _("expected exactly 1 device for the storage pool")); return -1; } } diff --git a/src/storage/storage_backend_zfs.c b/src/storage/storage_backend_zfs.c index 4e243a738a..178b505e92 100644 --- a/src/storage/storage_backend_zfs.c +++ b/src/storage/storage_backend_zfs.c @@ -310,8 +310,7 @@ virStorageBackendZFSCreateVol(virStoragePoolObj *pool, if (vol->target.encryption != NULL) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, - "%s", _("storage pool does not support encrypted " - "volumes")); + "%s", _("storage pool does not support encrypted volumes")); return -1; } diff --git a/src/storage/storage_driver.c b/src/storage/storage_driver.c index 5a9dcbd193..314fe930e0 100644 --- a/src/storage/storage_driver.c +++ b/src/storage/storage_driver.c @@ -1903,8 +1903,7 @@ storageVolCreateXML(virStoragePoolPtr pool, if (!voldef->target.capacity && !backend->buildVol) { virReportError(VIR_ERR_NO_SUPPORT, - "%s", _("volume capacity required for this " - "storage pool")); + "%s", _("volume capacity required for this storage pool")); goto cleanup; } @@ -1919,8 +1918,7 @@ storageVolCreateXML(virStoragePoolPtr pool, if (!backend->createVol) { virReportError(VIR_ERR_NO_SUPPORT, - "%s", _("storage pool does not support volume " - "creation")); + "%s", _("storage pool does not support volume creation")); goto cleanup; } @@ -2103,8 +2101,7 @@ storageVolCreateXMLFrom(virStoragePoolPtr pool, if (!backend->buildVolFrom) { virReportError(VIR_ERR_NO_SUPPORT, - "%s", _("storage pool does not support" - " volume creation from an existing volume")); + "%s", _("storage pool does not support volume creation from an existing volume")); goto cleanup; } @@ -2274,8 +2271,7 @@ virStorageBackendPloopRestoreDesc(char *path) if (virFileRemove(desc, 0, 0) < 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("refresh ploop failed:" - " unable to delete DiskDescriptor.xml")); + _("refresh ploop failed: unable to delete DiskDescriptor.xml")); return -1; } @@ -2497,16 +2493,14 @@ storageVolResize(virStorageVolPtr vol, if (abs_capacity < voldef->target.allocation) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("can't shrink capacity below " - "existing allocation")); + _("can't shrink capacity below existing allocation")); goto cleanup; } if (abs_capacity < voldef->target.capacity && !(flags & VIR_STORAGE_VOL_RESIZE_SHRINK)) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("Can't shrink capacity below current " - "capacity unless shrink flag explicitly specified")); + _("Can't shrink capacity below current capacity unless shrink flag explicitly specified")); goto cleanup; } @@ -2521,8 +2515,7 @@ storageVolResize(virStorageVolPtr vol, if (!backend->resizeVol) { virReportError(VIR_ERR_NO_SUPPORT, "%s", - _("storage pool does not support changing of " - "volume capacity")); + _("storage pool does not support changing of volume capacity")); goto cleanup; } diff --git a/src/storage/storage_util.c b/src/storage/storage_util.c index d39aa92eae..bf8de2475d 100644 --- a/src/storage/storage_util.c +++ b/src/storage/storage_util.c @@ -236,8 +236,7 @@ storageBackendCreateBlockFrom(virStoragePoolObj *pool G_GNUC_UNUSED, if (flags & VIR_STORAGE_VOL_CREATE_PREALLOC_METADATA) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("metadata preallocation is not supported for block " - "volumes")); + _("metadata preallocation is not supported for block volumes")); return -1; } @@ -389,8 +388,7 @@ storageBackendCreateRaw(virStoragePoolObj *pool, if (flags & VIR_STORAGE_VOL_CREATE_PREALLOC_METADATA) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("metadata preallocation is not supported for raw " - "volumes")); + _("metadata preallocation is not supported for raw volumes")); return -1; } @@ -571,8 +569,7 @@ storageBackendCreatePloop(virStoragePoolObj *pool G_GNUC_UNUSED, if (vol->target.encryption) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("encrypted ploop volumes are not supported with " - "ploop init")); + _("encrypted ploop volumes are not supported with ploop init")); return -1; } @@ -585,8 +582,7 @@ storageBackendCreatePloop(virStoragePoolObj *pool G_GNUC_UNUSED, create_tool = virFindFileInPath("ploop"); if (!create_tool && !inputvol) { virReportError(VIR_ERR_INTERNAL_ERROR, - "%s", _("unable to find ploop, please install " - "ploop tools")); + "%s", _("unable to find ploop, please install ploop tools")); return -1; } @@ -899,8 +895,7 @@ storageBackendCreateQemuImgSetBacking(virStoragePoolObj *pool, if (info->preallocate) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("metadata preallocation conflicts with backing" - " store")); + _("metadata preallocation conflicts with backing store")); return -1; } @@ -1273,8 +1268,7 @@ storageBackendCreateQemuImgSecretPath(virStoragePoolObj *pool, if (enc->nsecrets != 1) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("A single <secret type='passphrase'...> " - "element is expected in encryption description")); + _("A single <secret type='passphrase'...> element is expected in encryption description")); return NULL; } @@ -1365,8 +1359,7 @@ storageBackendCreateQemuImg(virStoragePoolObj *pool, create_tool = virFindFileInPath("qemu-img"); if (!create_tool) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("creation of non-raw file images is " - "not supported without qemu-img.")); + _("creation of non-raw file images is not supported without qemu-img.")); return -1; } @@ -2398,8 +2391,7 @@ virStorageBackendVolResizeLocal(virStoragePoolObj *pool, } else if (vol->target.format == VIR_STORAGE_FILE_RAW && vol->target.encryption) { if (pre_allocate) { virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("preallocate is only supported for an " - "unencrypted raw volume")); + _("preallocate is only supported for an unencrypted raw volume")); return -1; } @@ -2409,8 +2401,7 @@ virStorageBackendVolResizeLocal(virStoragePoolObj *pool, } else { if (pre_allocate) { virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("preallocate is only supported for raw " - "type volume")); + _("preallocate is only supported for raw type volume")); return -1; } @@ -2435,8 +2426,7 @@ storageBackendPloopHasSnapshots(char *path) snap_tool = virFindFileInPath("ploop"); if (!snap_tool) { virReportError(VIR_ERR_INTERNAL_ERROR, - "%s", _("unable to find ploop, please install " - "ploop tools")); + "%s", _("unable to find ploop, please install ploop tools")); return -1; } @@ -2478,8 +2468,7 @@ virStorageBackendVolUploadLocal(virStoragePoolObj *pool G_GNUC_UNUSED, return -1; } else if (!has_snap) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("can't upload volume, all existing snapshots" - " will be lost")); + _("can't upload volume, all existing snapshots will be lost")); return -1; } @@ -2512,8 +2501,7 @@ virStorageBackendVolDownloadLocal(virStoragePoolObj *pool G_GNUC_UNUSED, return -1; } else if (!has_snap) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("can't download volume, all existing snapshots" - " will be lost")); + _("can't download volume, all existing snapshots will be lost")); return -1; } path = g_strdup_printf("%s/root.hds", vol->target.path); @@ -3161,8 +3149,7 @@ virStorageBackendBLKIDFindEmpty(const char *device, if (ret == 0 && blkid_do_probe(probe) != 1) { virReportError(VIR_ERR_STORAGE_PROBE_FAILED, "%s", - _("Found additional probes to run, probing may " - "be incorrect")); + _("Found additional probes to run, probing may be incorrect")); ret = -1; } @@ -3287,8 +3274,7 @@ virStorageBackendPARTEDValidLabel(const char *device, switch (check) { case VIR_STORAGE_PARTED_ERROR: virReportError(VIR_ERR_OPERATION_FAILED, "%s", - _("Error checking for disk label, failed to get " - "disk partition information")); + _("Error checking for disk label, failed to get disk partition information")); break; case VIR_STORAGE_PARTED_MATCH: @@ -3302,8 +3288,7 @@ virStorageBackendPARTEDValidLabel(const char *device, case VIR_STORAGE_PARTED_DIFFERENT: virReportError(VIR_ERR_OPERATION_FAILED, "%s", - _("Known, but different label format present, " - "requires build --overwrite")); + _("Known, but different label format present, requires build --overwrite")); break; case VIR_STORAGE_PARTED_UNKNOWN: @@ -3316,8 +3301,7 @@ virStorageBackendPARTEDValidLabel(const char *device, case VIR_STORAGE_PARTED_NOPTTYPE: virReportError(VIR_ERR_OPERATION_FAILED, "%s", - _("Unable to determine Partition Type, " - "requires build --overwrite")); + _("Unable to determine Partition Type, requires build --overwrite")); break; case VIR_STORAGE_PARTED_PTTYPE_UNK: -- 2.41.0

Error messages are exempt from the 80 columns rule. Move them onto one line. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/storage_file/storage_source.c | 3 +- .../storage_source_backingstore.c | 36 +++++++------------ 2 files changed, 13 insertions(+), 26 deletions(-) diff --git a/src/storage_file/storage_source.c b/src/storage_file/storage_source.c index 3c50239e29..b97bbde619 100644 --- a/src/storage_file/storage_source.c +++ b/src/storage_file/storage_source.c @@ -762,8 +762,7 @@ virStorageSourceGetRelativeBackingPath(virStorageSource *top, if (next != base) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("failed to resolve relative backing name: " - "base image is not in backing chain")); + _("failed to resolve relative backing name: base image is not in backing chain")); return -1; } diff --git a/src/storage_file/storage_source_backingstore.c b/src/storage_file/storage_source_backingstore.c index a4ee2a5d78..00fcfe9fd7 100644 --- a/src/storage_file/storage_source_backingstore.c +++ b/src/storage_file/storage_source_backingstore.c @@ -441,8 +441,7 @@ virStorageSourceParseBackingJSONPath(virStorageSource *src, if (!(path = virJSONValueObjectGetString(json, "filename"))) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("missing 'filename' field in JSON backing volume " - "definition")); + _("missing 'filename' field in JSON backing volume definition")); return -1; } @@ -597,8 +596,7 @@ virStorageSourceParseBackingJSONInetSocketAddress(virStorageNetHostDef *host, if (!json) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("missing remote server specification in JSON " - "backing volume definition")); + _("missing remote server specification in JSON backing volume definition")); return -1; } @@ -607,8 +605,7 @@ virStorageSourceParseBackingJSONInetSocketAddress(virStorageNetHostDef *host, if (!hostname) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("missing hostname for tcp backing server in " - "JSON backing volume definition")); + _("missing hostname for tcp backing server in JSON backing volume definition")); return -1; } @@ -631,15 +628,13 @@ virStorageSourceParseBackingJSONSocketAddress(virStorageNetHostDef *host, if (!json) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("missing remote server specification in JSON " - "backing volume definition")); + _("missing remote server specification in JSON backing volume definition")); return -1; } if (!(type = virJSONValueObjectGetString(json, "type"))) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("missing socket address type in " - "JSON backing volume definition")); + _("missing socket address type in JSON backing volume definition")); return -1; } @@ -657,8 +652,7 @@ virStorageSourceParseBackingJSONSocketAddress(virStorageNetHostDef *host, if (!socket) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("missing socket path for udp backing server in " - "JSON backing volume definition")); + _("missing socket path for udp backing server in JSON backing volume definition")); return -1; } @@ -694,8 +688,7 @@ virStorageSourceParseBackingJSONGluster(virStorageSource *src, if (!volume || !path || !server) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("missing 'volume', 'path' or 'server' attribute in " - "JSON backing definition for gluster volume")); + _("missing 'volume', 'path' or 'server' attribute in JSON backing definition for gluster volume")); return -1; } @@ -708,8 +701,7 @@ virStorageSourceParseBackingJSONGluster(virStorageSource *src, nservers = virJSONValueArraySize(server); if (nservers == 0) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("at least 1 server is necessary in " - "JSON backing definition for gluster volume")); + _("at least 1 server is necessary in JSON backing definition for gluster volume")); return -1; } @@ -809,8 +801,7 @@ virStorageSourceParseBackingJSONNbd(virStorageSource *src, if (!path && !host && !server) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("missing host specification of NBD server in JSON " - "backing volume definition")); + _("missing host specification of NBD server in JSON backing volume definition")); return -1; } @@ -899,8 +890,7 @@ virStorageSourceParseBackingJSONSSH(virStorageSource *src, if (!(host || server) || !path) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("missing host/server or path of SSH JSON backing " - "volume definition")); + _("missing host/server or path of SSH JSON backing volume definition")); return -1; } @@ -957,8 +947,7 @@ virStorageSourceParseBackingJSONRBD(virStorageSource *src, if (!pool || !image) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("missing pool or image name in ceph backing volume " - "JSON specification")); + _("missing pool or image name in ceph backing volume JSON specification")); return -1; } @@ -1034,8 +1023,7 @@ virStorageSourceParseBackingJSONVxHS(virStorageSource *src, if (!vdisk_id || !server) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("missing 'vdisk-id' or 'server' attribute in " - "JSON backing definition for VxHS volume")); + _("missing 'vdisk-id' or 'server' attribute in JSON backing definition for VxHS volume")); return -1; } -- 2.41.0

Error messages are exempt from the 80 columns rule. Move them onto one line. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/test/test_driver.c | 39 +++++++++++++-------------------------- 1 file changed, 13 insertions(+), 26 deletions(-) diff --git a/src/test/test_driver.c b/src/test/test_driver.c index 905be3853b..5908489a50 100644 --- a/src/test/test_driver.c +++ b/src/test/test_driver.c @@ -2691,8 +2691,7 @@ static int testDomainSetMemoryStatsPeriod(virDomainPtr dom, if (!virDomainDefHasMemballoon(def)) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("No memory balloon device configured, " - "can not set the collection period")); + _("No memory balloon device configured, can not set the collection period")); goto cleanup; } @@ -2727,22 +2726,19 @@ static int testDomainSetMemoryFlags(virDomainPtr domain, if (flags & VIR_DOMAIN_MEM_MAXIMUM) { if (live) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("cannot resize the maximum memory on an " - "active domain")); + _("cannot resize the maximum memory on an active domain")); goto cleanup; } if (virDomainNumaGetNodeCount(def->numa) > 0) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("initial memory size of a domain with NUMA " - "nodes cannot be modified with this API")); + _("initial memory size of a domain with NUMA nodes cannot be modified with this API")); goto cleanup; } if (def->mem.max_memory && def->mem.max_memory < memory) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("cannot set initial memory size greater than " - "the maximum memory size")); + _("cannot set initial memory size greater than the maximum memory size")); goto cleanup; } @@ -3413,8 +3409,7 @@ testDomainSetMemoryParameters(virDomainPtr dom, if (mem_limit > swap_limit) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("memory hard_limit tunable value must be lower " - "than or equal to swap_hard_limit")); + _("memory hard_limit tunable value must be lower than or equal to swap_hard_limit")); goto cleanup; } } @@ -3945,32 +3940,28 @@ testDomainSetBlockIoTune(virDomainPtr dom, if ((info.total_bytes_sec && info.read_bytes_sec) || (info.total_bytes_sec && info.write_bytes_sec)) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("total and read/write of bytes_sec " - "cannot be set at the same time")); + _("total and read/write of bytes_sec cannot be set at the same time")); goto cleanup; } if ((info.total_iops_sec && info.read_iops_sec) || (info.total_iops_sec && info.write_iops_sec)) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("total and read/write of iops_sec " - "cannot be set at the same time")); + _("total and read/write of iops_sec cannot be set at the same time")); goto cleanup; } if ((info.total_bytes_sec_max && info.read_bytes_sec_max) || (info.total_bytes_sec_max && info.write_bytes_sec_max)) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("total and read/write of bytes_sec_max " - "cannot be set at the same time")); + _("total and read/write of bytes_sec_max cannot be set at the same time")); goto cleanup; } if ((info.total_iops_sec_max && info.read_iops_sec_max) || (info.total_iops_sec_max && info.write_iops_sec_max)) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("total and read/write of iops_sec_max " - "cannot be set at the same time")); + _("total and read/write of iops_sec_max cannot be set at the same time")); goto cleanup; } @@ -4578,8 +4569,7 @@ static int testDomainUndefineFlags(virDomainPtr domain, if (privdom->hasManagedSave && !(flags & VIR_DOMAIN_UNDEFINE_MANAGED_SAVE)) { 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; } @@ -6053,8 +6043,7 @@ testInterfaceChangeCommit(virConnectPtr conn, if (!privconn->transaction_running) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("no transaction running, " - "nothing to be committed.")); + _("no transaction running, nothing to be committed.")); goto cleanup; } @@ -6083,8 +6072,7 @@ testInterfaceChangeRollback(virConnectPtr conn, if (!privconn->transaction_running) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("no transaction running, " - "nothing to rollback.")); + _("no transaction running, nothing to rollback.")); goto cleanup; } @@ -9015,8 +9003,7 @@ testDomainRevertToSnapshot(virDomainSnapshotPtr snapshot, (flags & (VIR_DOMAIN_SNAPSHOT_REVERT_RUNNING | VIR_DOMAIN_SNAPSHOT_REVERT_PAUSED)) == 0) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("transient domain needs to request run or pause " - "to revert to inactive snapshot")); + _("transient domain needs to request run or pause to revert to inactive snapshot")); goto cleanup; } -- 2.41.0

Error messages are exempt from the 80 columns rule. Move them onto one line. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/util/vircgroupv2devices.c | 13 ++++--------- src/util/vircommand.c | 3 +-- src/util/virfile.c | 3 +-- src/util/virhostcpu.c | 3 +-- src/util/virhostmem.c | 6 ++---- src/util/virjson.c | 3 +-- src/util/virmdev.c | 3 +-- src/util/virnetdev.c | 12 ++++-------- src/util/virnetdevbandwidth.c | 6 ++---- src/util/virnetdevopenvswitch.c | 6 ++---- src/util/virnetdevvportprofile.c | 6 ++---- src/util/virnetlink.c | 3 +-- src/util/virnuma.c | 6 ++---- src/util/virpci.c | 3 +-- src/util/virprocess.c | 9 +++------ src/util/virqemu.c | 3 +-- src/util/virresctrl.c | 9 +++------ src/util/virthreadpool.c | 3 +-- 18 files changed, 33 insertions(+), 67 deletions(-) diff --git a/src/util/vircgroupv2devices.c b/src/util/vircgroupv2devices.c index f740127bbc..7deb233c06 100644 --- a/src/util/vircgroupv2devices.c +++ b/src/util/vircgroupv2devices.c @@ -444,9 +444,7 @@ virCgroupV2DevicesCreateMap(size_t size) if (mapfd < 0) { if (errno == EPERM) { virReportSystemError(errno, "%s", - _("failed to initialize device BPF map; " - "locked memory limit for libvirtd probably " - "needs to be raised")); + _("failed to initialize device BPF map; locked memory limit for libvirtd probably needs to be raised")); return -1; } else { virReportSystemError(errno, "%s", @@ -595,8 +593,7 @@ int virCgroupV2DevicesDetectProg(virCgroup *group G_GNUC_UNUSED) { virReportSystemError(ENOSYS, "%s", - _("cgroups v2 BPF devices not supported " - "with this kernel")); + _("cgroups v2 BPF devices not supported with this kernel")); return -1; } @@ -605,8 +602,7 @@ int virCgroupV2DevicesCreateProg(virCgroup *group G_GNUC_UNUSED) { virReportSystemError(ENOSYS, "%s", - _("cgroups v2 BPF devices not supported " - "with this kernel")); + _("cgroups v2 BPF devices not supported with this kernel")); return -1; } @@ -615,8 +611,7 @@ int virCgroupV2DevicesPrepareProg(virCgroup *group G_GNUC_UNUSED) { virReportSystemError(ENOSYS, "%s", - _("cgroups v2 BPF devices not supported " - "with this kernel")); + _("cgroups v2 BPF devices not supported with this kernel")); return -1; } diff --git a/src/util/vircommand.c b/src/util/vircommand.c index 5f094c625a..704069815a 100644 --- a/src/util/vircommand.c +++ b/src/util/vircommand.c @@ -2691,8 +2691,7 @@ virCommandRunAsync(virCommand *cmd, pid_t *pid) virCommandDoAsyncIOHelper, "cmd-async-io", false, cmd) < 0) { virReportSystemError(errno, "%s", - _("Unable to create thread " - "to process command's IO")); + _("Unable to create thread to process command's IO")); VIR_FREE(cmd->asyncioThread); virCommandAbort(cmd); ret = -1; diff --git a/src/util/virfile.c b/src/util/virfile.c index 0600e4a172..bd36a9a31a 100644 --- a/src/util/virfile.c +++ b/src/util/virfile.c @@ -1094,8 +1094,7 @@ virFileNBDLoadDriver(void) { if (virKModIsProhibited(NBD_DRIVER)) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Failed to load nbd module: " - "administratively prohibited")); + _("Failed to load nbd module: administratively prohibited")); return false; } else { g_autofree char *errbuf = NULL; diff --git a/src/util/virhostcpu.c b/src/util/virhostcpu.c index a15731e9ea..0389012ef7 100644 --- a/src/util/virhostcpu.c +++ b/src/util/virhostcpu.c @@ -892,8 +892,7 @@ virHostCPUStatsAssign(virNodeCPUStatsPtr param, { if (virStrcpyStatic(param->field, name) < 0) { virReportError(VIR_ERR_INTERNAL_ERROR, - "%s", _("kernel cpu time field is too long" - " for the destination")); + "%s", _("kernel cpu time field is too long for the destination")); return -1; } param->value = value; diff --git a/src/util/virhostmem.c b/src/util/virhostmem.c index 83c10206cd..1da2759ac3 100644 --- a/src/util/virhostmem.c +++ b/src/util/virhostmem.c @@ -392,8 +392,7 @@ virHostMemSetParameters(virTypedParameterPtr params G_GNUC_UNUSED, virCheckFlags(0, -1); virReportError(VIR_ERR_NO_SUPPORT, "%s", - _("node set memory parameters not implemented" - " on this platform")); + _("node set memory parameters not implemented on this platform")); return -1; } #endif @@ -586,8 +585,7 @@ virHostMemGetParameters(virTypedParameterPtr params G_GNUC_UNUSED, virCheckFlags(VIR_TYPED_PARAM_STRING_OKAY, -1); virReportError(VIR_ERR_NO_SUPPORT, "%s", - _("node get memory parameters not implemented" - " on this platform")); + _("node get memory parameters not implemented on this platform")); return -1; } #endif diff --git a/src/util/virjson.c b/src/util/virjson.c index 7e20443f93..03c3b6cfb9 100644 --- a/src/util/virjson.c +++ b/src/util/virjson.c @@ -1938,8 +1938,7 @@ virJSONValueObjectDeflattenWorker(const char *key, } else { if (!virJSONValueIsObject(existobj)) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("mixing nested objects and values is forbidden in " - "JSON deflattening")); + _("mixing nested objects and values is forbidden in JSON deflattening")); return -1; } } diff --git a/src/util/virmdev.c b/src/util/virmdev.c index d0f35ca347..992f3eb1b7 100644 --- a/src/util/virmdev.c +++ b/src/util/virmdev.c @@ -167,8 +167,7 @@ virMediatedDeviceNew(const char *uuidstr G_GNUC_UNUSED, virMediatedDeviceModelType model G_GNUC_UNUSED) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("mediated devices are not supported on non-linux " - "platforms")); + _("mediated devices are not supported on non-linux platforms")); return NULL; } diff --git a/src/util/virnetdev.c b/src/util/virnetdev.c index 46d90fbd76..8ae854245e 100644 --- a/src/util/virnetdev.c +++ b/src/util/virnetdev.c @@ -182,8 +182,7 @@ virNetDevSetupControl(const char *ifname G_GNUC_UNUSED, void *ifr G_GNUC_UNUSED) { virReportSystemError(ENOSYS, "%s", - _("Network device configuration is not supported " - "on this platform")); + _("Network device configuration is not supported on this platform")); return -1; } #endif /* WITH_STRUCT_IFREQ */ @@ -2248,8 +2247,7 @@ virNetDevSetNetConfig(const char *linkdev, int vf, if (vlan) { if (vlan->nTags != 1 || vlan->trunk) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("vlan trunking is not supported " - "by SR-IOV network devices")); + _("vlan trunking is not supported by SR-IOV network devices")); return -1; } @@ -2651,8 +2649,7 @@ int virNetDevAddMulti(const char *ifname G_GNUC_UNUSED, virMacAddr *macaddr G_GNUC_UNUSED) { virReportSystemError(ENOSYS, "%s", - _("Unable to add address to interface " - "multicast list on this platform")); + _("Unable to add address to interface multicast list on this platform")); return -1; } #endif @@ -2696,8 +2693,7 @@ int virNetDevDelMulti(const char *ifname G_GNUC_UNUSED, virMacAddr *macaddr G_GNUC_UNUSED) { virReportSystemError(ENOSYS, "%s", - _("Unable to delete address from interface " - "multicast list on this platform")); + _("Unable to delete address from interface multicast list on this platform")); return -1; } #endif diff --git a/src/util/virnetdevbandwidth.c b/src/util/virnetdevbandwidth.c index 52fb94a9fc..ec41666f67 100644 --- a/src/util/virnetdevbandwidth.c +++ b/src/util/virnetdevbandwidth.c @@ -208,15 +208,13 @@ virNetDevBandwidthSet(const char *ifname, if (geteuid() != 0) { virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("Network bandwidth tuning is not available" - " in session mode")); + _("Network bandwidth tuning is not available in session mode")); return -1; } if (!ifname) { virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("Unable to set bandwidth for interface because " - "device name is unknown")); + _("Unable to set bandwidth for interface because device name is unknown")); return -1; } diff --git a/src/util/virnetdevopenvswitch.c b/src/util/virnetdevopenvswitch.c index dbdd645f8e..8dad6ed2bd 100644 --- a/src/util/virnetdevopenvswitch.c +++ b/src/util/virnetdevopenvswitch.c @@ -894,15 +894,13 @@ virNetDevOpenvswitchInterfaceSetQos(const char *ifname, if (geteuid() != 0) { virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("Network bandwidth tuning is not available" - " in session mode")); + _("Network bandwidth tuning is not available in session mode")); return -1; } if (!ifname) { virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", - _("Unable to set bandwidth for interface because " - "device name is unknown")); + _("Unable to set bandwidth for interface because device name is unknown")); return -1; } diff --git a/src/util/virnetdevvportprofile.c b/src/util/virnetdevvportprofile.c index cf92f1838b..33bcd350c4 100644 --- a/src/util/virnetdevvportprofile.c +++ b/src/util/virnetdevvportprofile.c @@ -530,8 +530,7 @@ virNetDevVPortProfileGetStatus(struct nlattr **tb, int32_t vf, if (nla_type(tb_vf_ports) != IFLA_VF_PORT) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("error while iterating over " - "IFLA_VF_PORTS part")); + _("error while iterating over IFLA_VF_PORTS part")); return -1; } @@ -584,8 +583,7 @@ virNetDevVPortProfileGetStatus(struct nlattr **tb, int32_t vf, if (nla_parse_nested(tb_port, IFLA_PORT_MAX, tb_vf_ports, ifla_port_policy)) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("error parsing IFLA_VF_PORT " - "during error reporting")); + _("error parsing IFLA_VF_PORT during error reporting")); return -1; } if (tb_port[IFLA_PORT_INSTANCE_UUID]) { diff --git a/src/util/virnetlink.c b/src/util/virnetlink.c index 2d052cd03e..24cd69a385 100644 --- a/src/util/virnetlink.c +++ b/src/util/virnetlink.c @@ -225,8 +225,7 @@ virNetlinkCreateSocket(int protocol) if (virNetlinkSetBufferSize(nlhandle, 131702, 0) < 0) { virReportSystemError(errno, "%s", - _("cannot set netlink socket buffer " - "size to 128k")); + _("cannot set netlink socket buffer size to 128k")); goto error; } nl_socket_enable_msg_peek(nlhandle); diff --git a/src/util/virnuma.c b/src/util/virnuma.c index e8bbaf0947..5053a70c61 100644 --- a/src/util/virnuma.c +++ b/src/util/virnuma.c @@ -69,8 +69,7 @@ virNumaGetAutoPlacementAdvice(unsigned short vcpus, if (virCommandRun(cmd, NULL) < 0) { virReportError(VIR_ERR_OPERATION_FAILED, "%s", - _("Failed to query numad for the " - "advisory nodeset")); + _("Failed to query numad for the advisory nodeset")); VIR_FREE(output); } @@ -149,8 +148,7 @@ virNumaSetupMemoryPolicy(virDomainNumatuneMemMode mode, if (!has_preferred_many && nnodes != 1) { virReportError(VIR_ERR_INTERNAL_ERROR, - "%s", _("NUMA memory tuning in 'preferred' mode " - "only supports single node")); + "%s", _("NUMA memory tuning in 'preferred' mode only supports single node")); return -1; } diff --git a/src/util/virpci.c b/src/util/virpci.c index 1158e468bf..08b82708b1 100644 --- a/src/util/virpci.c +++ b/src/util/virpci.c @@ -1454,8 +1454,7 @@ virPCIDeviceAddressIsValid(virPCIDeviceAddress *addr, if (virPCIDeviceAddressIsEmpty(addr)) { if (report) virReportError(VIR_ERR_XML_ERROR, "%s", - _("Invalid PCI address 0000:00:00, at least " - "one of domain, bus, or slot must be > 0")); + _("Invalid PCI address 0000:00:00, at least one of domain, bus, or slot must be > 0")); return false; } return true; diff --git a/src/util/virprocess.c b/src/util/virprocess.c index f8daa786c9..7c0f63efbb 100644 --- a/src/util/virprocess.c +++ b/src/util/virprocess.c @@ -1621,15 +1621,13 @@ virProcessSetScheduler(pid_t pid, if ((min = sched_get_priority_min(pol)) < 0) { virReportSystemError(errno, "%s", - _("Cannot get minimum scheduler " - "priority value")); + _("Cannot get minimum scheduler priority value")); return -1; } if ((max = sched_get_priority_max(pol)) < 0) { virReportSystemError(errno, "%s", - _("Cannot get maximum scheduler " - "priority value")); + _("Cannot get maximum scheduler priority value")); return -1; } @@ -1664,8 +1662,7 @@ virProcessSetScheduler(pid_t pid G_GNUC_UNUSED, return 0; virReportSystemError(ENOSYS, "%s", - _("Process CPU scheduling is not supported " - "on this platform")); + _("Process CPU scheduling is not supported on this platform")); return -1; } diff --git a/src/util/virqemu.c b/src/util/virqemu.c index b9e57a6f4c..c9fac5956a 100644 --- a/src/util/virqemu.c +++ b/src/util/virqemu.c @@ -207,8 +207,7 @@ virQEMUBuildCommandLineJSONRecurse(const char *key, case VIR_JSON_TYPE_ARRAY: if (nested) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("nested JSON array to commandline conversion is " - "not supported")); + _("nested JSON array to commandline conversion is not supported")); return -1; } diff --git a/src/util/virresctrl.c b/src/util/virresctrl.c index 1e98b111f2..8ca58f5d10 100644 --- a/src/util/virresctrl.c +++ b/src/util/virresctrl.c @@ -496,8 +496,7 @@ static int virResctrlLock(void) { virReportSystemError(ENOSYS, "%s", - _("resctrl locking is not supported " - "on this platform")); + _("resctrl locking is not supported on this platform")); return -1; } @@ -506,8 +505,7 @@ static int virResctrlUnlock(int fd G_GNUC_UNUSED) { virReportSystemError(ENOSYS, "%s", - _("resctrl locking is not supported " - "on this platform")); + _("resctrl locking is not supported on this platform")); return -1; } @@ -1468,8 +1466,7 @@ virResctrlAllocParseMemoryBandwidthLine(virResctrlInfo *resctrl, !resctrl->membw_info->min_bandwidth || !resctrl->membw_info->bandwidth_granularity) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Missing or inconsistent resctrl info for " - "memory bandwidth allocation")); + _("Missing or inconsistent resctrl info for memory bandwidth allocation")); return -1; } diff --git a/src/util/virthreadpool.c b/src/util/virthreadpool.c index 2f1d49d665..d45fa92061 100644 --- a/src/util/virthreadpool.c +++ b/src/util/virthreadpool.c @@ -429,8 +429,7 @@ virThreadPoolSetParameters(virThreadPool *pool, if ((maxWorkers == 0 && pool->maxWorkers > 0) || (maxWorkers > 0 && pool->maxWorkers == 0)) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("maxWorkers must not be switched from zero to non-zero" - " and vice versa")); + _("maxWorkers must not be switched from zero to non-zero and vice versa")); return -1; } -- 2.41.0

Error messages are exempt from the 80 columns rule. Move them onto one line. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/vbox/vbox_snapshot_conf.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/vbox/vbox_snapshot_conf.c b/src/vbox/vbox_snapshot_conf.c index 6dbd18d657..84f7aceac2 100644 --- a/src/vbox/vbox_snapshot_conf.c +++ b/src/vbox/vbox_snapshot_conf.c @@ -736,8 +736,7 @@ virVBoxSnapshotConfAddSnapshotToXmlMachine(virVBoxSnapshotConfSnapshot *snapshot if (snapshotParentName == NULL) { if (machine->snapshot != NULL) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Unable to add this snapshot, there is already a snapshot " - "linked to the machine")); + _("Unable to add this snapshot, there is already a snapshot linked to the machine")); return -1; } machine->snapshot = snapshot; @@ -840,8 +839,7 @@ virVBoxSnapshotConfRemoveSnapshot(virVBoxSnapshotConfMachine *machine, } if (snapshot->nchildren > 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("This snapshot has children, " - "please delete these snapshots before")); + _("This snapshot has children, please delete these snapshots before")); return -1; } -- 2.41.0

Error messages are exempt from the 80 columns rule. Move them onto one line. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/vmware/vmware_conf.c | 9 +++------ src/vmware/vmware_driver.c | 6 ++---- 2 files changed, 5 insertions(+), 10 deletions(-) diff --git a/src/vmware/vmware_conf.c b/src/vmware/vmware_conf.c index ba4e4d28dc..a598b512dc 100644 --- a/src/vmware/vmware_conf.c +++ b/src/vmware/vmware_conf.c @@ -355,8 +355,7 @@ vmwareVmxPath(virDomainDef *vmdef, char **vmxPath) */ if (vmdef->ndisks < 1) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Domain XML doesn't contain any disks, " - "cannot deduce datastore and path for VMX file")); + _("Domain XML doesn't contain any disks, cannot deduce datastore and path for VMX file")); return -1; } @@ -370,16 +369,14 @@ vmwareVmxPath(virDomainDef *vmdef, char **vmxPath) if (disk == NULL) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Domain XML doesn't contain any file-based harddisks, " - "cannot deduce datastore and path for VMX file")); + _("Domain XML doesn't contain any file-based harddisks, cannot deduce datastore and path for VMX file")); return -1; } src = virDomainDiskGetSource(disk); if (!src) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("First file-based harddisk has no source, cannot " - "deduce datastore and path for VMX file")); + _("First file-based harddisk has no source, cannot deduce datastore and path for VMX file")); return -1; } diff --git a/src/vmware/vmware_driver.c b/src/vmware/vmware_driver.c index 259d00cacd..416ce126e8 100644 --- a/src/vmware/vmware_driver.c +++ b/src/vmware/vmware_driver.c @@ -509,8 +509,7 @@ vmwareDomainSuspend(virDomainPtr dom) if (driver->type == VMWARE_DRIVER_PLAYER) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("vmplayer does not support libvirt suspend/resume" - " (vmware pause/unpause) operation ")); + _("vmplayer does not support libvirt suspend/resume (vmware pause/unpause) operation ")); return ret; } @@ -549,8 +548,7 @@ vmwareDomainResume(virDomainPtr dom) if (driver->type == VMWARE_DRIVER_PLAYER) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("vmplayer does not support libvirt suspend/resume " - "(vmware pause/unpause) operation ")); + _("vmplayer does not support libvirt suspend/resume (vmware pause/unpause) operation ")); return ret; } -- 2.41.0

Error messages are exempt from the 80 columns rule. Move them onto one line. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/vmx/vmx.c | 21 +++++++-------------- 1 file changed, 7 insertions(+), 14 deletions(-) diff --git a/src/vmx/vmx.c b/src/vmx/vmx.c index 5c6925be22..26b89776e1 100644 --- a/src/vmx/vmx.c +++ b/src/vmx/vmx.c @@ -938,8 +938,7 @@ virVMXSCSIDiskNameToControllerAndUnit(const char *name, int *controller, int *un if (! STRPREFIX(name, "sd")) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Expecting domain XML attribute 'dev' of entry " - "'devices/disk/target' to start with 'sd'")); + _("Expecting domain XML attribute 'dev' of entry 'devices/disk/target' to start with 'sd'")); return -1; } @@ -977,8 +976,7 @@ virVMXIDEDiskNameToBusAndUnit(const char *name, int *bus, int *unit) if (! STRPREFIX(name, "hd")) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Expecting domain XML attribute 'dev' of entry " - "'devices/disk/target' to start with 'hd'")); + _("Expecting domain XML attribute 'dev' of entry 'devices/disk/target' to start with 'hd'")); return -1; } @@ -1012,8 +1010,7 @@ virVMXFloppyDiskNameToUnit(const char *name, int *unit) if (! STRPREFIX(name, "fd")) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Expecting domain XML attribute 'dev' of entry " - "'devices/disk/target' to start with 'fd'")); + _("Expecting domain XML attribute 'dev' of entry 'devices/disk/target' to start with 'fd'")); return -1; } @@ -1505,8 +1502,7 @@ virVMXParseConfig(virVMXContext *ctx, if (def->description != NULL) { if (virVMXUnescapeHexPipe(def->description) < 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("VMX entry 'annotation' contains invalid escape " - "sequence")); + _("VMX entry 'annotation' contains invalid escape sequence")); goto cleanup; } } @@ -1583,8 +1579,7 @@ virVMXParseConfig(virVMXContext *ctx, cpu->sockets = numvcpus / coresPerSocket; if (cpu->sockets <= 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("VMX entry 'cpuid.coresPerSocket' smaller than " - "'numvcpus'")); + _("VMX entry 'cpuid.coresPerSocket' smaller than 'numvcpus'")); goto cleanup; } cpu->dies = 1; @@ -3348,15 +3343,13 @@ virVMXFormatConfig(virVMXContext *ctx, virDomainXMLOption *xmlopt, virDomainDef /* def:maxvcpus -> vmx:numvcpus */ if (virDomainDefHasVcpusOffline(def)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("No support for domain XML entry 'vcpu' attribute " - "'current'")); + _("No support for domain XML entry 'vcpu' attribute 'current'")); goto cleanup; } maxvcpus = virDomainDefGetVcpusMax(def); if (maxvcpus == 0) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("Expecting domain XML entry 'vcpu' to be greater " - "than 0")); + _("Expecting domain XML entry 'vcpu' to be greater than 0")); goto cleanup; } -- 2.41.0

Error messages are exempt from the 80 columns rule. Move them onto one line. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/vz/vz_driver.c | 15 ++--- src/vz/vz_sdk.c | 135 +++++++++++++++------------------------------ src/vz/vz_utils.c | 66 ++++++++-------------- 3 files changed, 72 insertions(+), 144 deletions(-) diff --git a/src/vz/vz_driver.c b/src/vz/vz_driver.c index 401ca041ed..c7ceec2339 100644 --- a/src/vz/vz_driver.c +++ b/src/vz/vz_driver.c @@ -842,8 +842,7 @@ vzDomainDefineXMLFlags(virConnectPtr conn, const char *xml, unsigned int flags) if (!virDomainDefCheckABIStability(dom->def, def, driver->xmlopt)) { virReportError(VIR_ERR_ARGUMENT_UNSUPPORTED, "%s", - _("Can't change domain configuration " - "in managed save state")); + _("Can't change domain configuration in managed save state")); goto cleanup; } } else { @@ -1461,15 +1460,13 @@ static int vzCheckConfigUpdateFlags(virDomainObj *dom, unsigned int *flags) if (!(*flags & VIR_DOMAIN_AFFECT_CONFIG)) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("domain config update needs VIR_DOMAIN_AFFECT_CONFIG " - "flag to be set")); + _("domain config update needs VIR_DOMAIN_AFFECT_CONFIG flag to be set")); return -1; } if (virDomainObjIsActive(dom) && !(*flags & VIR_DOMAIN_AFFECT_LIVE)) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("Updates on a running domain need " - "VIR_DOMAIN_AFFECT_LIVE flag")); + _("Updates on a running domain need VIR_DOMAIN_AFFECT_LIVE flag")); return -1; } @@ -2793,8 +2790,7 @@ vzEatCookie(const char *cookiein, int cookieinlen, unsigned int flags) if ((!(tmp = virXPathString("string(./session-uuid[1])", ctx)) || (virUUIDParse(tmp, mig->session_uuid) < 0))) { virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("missing or malformed session-uuid element " - "in migration data")); + _("missing or malformed session-uuid element in migration data")); goto error; } } @@ -2921,8 +2917,7 @@ vzMigrationCreateURI(void) 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 cleanup; } diff --git a/src/vz/vz_sdk.c b/src/vz/vz_sdk.c index 286b52a29e..6a15d60577 100644 --- a/src/vz/vz_sdk.c +++ b/src/vz/vz_sdk.c @@ -2415,15 +2415,13 @@ prlsdkCheckUnsupportedParams(PRL_HANDLE sdkdom, virDomainDef *def) if (def->blkio.ndevices > 0) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("blkio parameters are not supported " - "by vz driver")); + _("blkio parameters are not supported by vz driver")); return -1; } if (virDomainDefGetMemoryTotal(def) != def->mem.cur_balloon) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("changing balloon parameters is not supported " - "by vz driver")); + _("changing balloon parameters is not supported by vz driver")); return -1; } @@ -2440,8 +2438,7 @@ prlsdkCheckUnsupportedParams(PRL_HANDLE sdkdom, virDomainDef *def) virMemoryLimitIsSet(def->mem.swap_hard_limit)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Memory parameter is not supported " - "by vz driver")); + _("Memory parameter is not supported by vz driver")); return -1; } @@ -2453,8 +2450,7 @@ prlsdkCheckUnsupportedParams(PRL_HANDLE sdkdom, virDomainDef *def) if (def->placement_mode) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("changing cpu placement mode is not supported " - "by vz driver")); + _("changing cpu placement mode is not supported by vz driver")); return -1; } @@ -2489,8 +2485,7 @@ prlsdkCheckUnsupportedParams(PRL_HANDLE sdkdom, virDomainDef *def) memMode == VIR_DOMAIN_NUMATUNE_MEM_STRICT) || virDomainNumatuneHasPerNodeBinding(def->numa)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("numa parameters are not supported " - "by vz driver")); + _("numa parameters are not supported by vz driver")); return -1; } @@ -2499,8 +2494,7 @@ prlsdkCheckUnsupportedParams(PRL_HANDLE sdkdom, virDomainDef *def) def->onCrash != VIR_DOMAIN_LIFECYCLE_ACTION_DESTROY) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("on_reboot, on_poweroff and on_crash parameters " - "are not supported by vz driver")); + _("on_reboot, on_poweroff and on_crash parameters are not supported by vz driver")); return -1; } @@ -2516,8 +2510,7 @@ prlsdkCheckUnsupportedParams(PRL_HANDLE sdkdom, virDomainDef *def) def->os.bios.useserial != 0) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("changing OS parameters is not supported " - "by vz driver")); + _("changing OS parameters is not supported by vz driver")); return -1; } @@ -2531,8 +2524,7 @@ prlsdkCheckUnsupportedParams(PRL_HANDLE sdkdom, virDomainDef *def) !(vmType == PVT_CT && IS_CT(def))) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("changing OS type is not supported " - "by vz driver")); + _("changing OS type is not supported by vz driver")); return -1; } @@ -2555,16 +2547,14 @@ prlsdkCheckUnsupportedParams(PRL_HANDLE sdkdom, virDomainDef *def) if (def->emulator) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("changing emulator is not supported " - "by vz driver")); + _("changing emulator is not supported by vz driver")); return -1; } for (i = 0; i < VIR_DOMAIN_FEATURE_LAST; i++) { if (def->features[i]) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("changing features is not supported " - "by vz driver")); + _("changing features is not supported by vz driver")); return -1; } } @@ -2573,15 +2563,13 @@ prlsdkCheckUnsupportedParams(PRL_HANDLE sdkdom, virDomainDef *def) def->clock.ntimers != 0) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("changing clock parameters is not supported " - "by vz driver")); + _("changing clock parameters is not supported by vz driver")); return -1; } if (!IS_CT(def) && def->nfss != 0) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Filesystems in VMs are not supported " - "by vz driver")); + _("Filesystems in VMs are not supported by vz driver")); return -1; } @@ -2591,8 +2579,7 @@ prlsdkCheckUnsupportedParams(PRL_HANDLE sdkdom, virDomainDef *def) def->nleases != 0 || def->nhubs != 0) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("changing devices parameters is not supported " - "by vz driver")); + _("changing devices parameters is not supported by vz driver")); return -1; } @@ -2716,15 +2703,13 @@ static int prlsdkCheckVideoUnsupportedParams(virDomainDef *def) return 0; } else { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Video adapters are not supported " - "int containers.")); + _("Video adapters are not supported int containers.")); return -1; } } else { if (def->nvideos != 1) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("vz driver supports " - "only one video adapter.")); + _("vz driver supports only one video adapter.")); return -1; } } @@ -2733,22 +2718,19 @@ static int prlsdkCheckVideoUnsupportedParams(virDomainDef *def) if (v->type != VIR_DOMAIN_VIDEO_TYPE_VGA) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("vz driver supports " - "only VGA video adapters.")); + _("vz driver supports only VGA video adapters.")); return -1; } if (v->heads != 1) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("vz driver doesn't support " - "multihead video adapters.")); + _("vz driver doesn't support multihead video adapters.")); return -1; } if (v->accel != NULL && (v->accel->accel2d || v->accel->accel3d)) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("vz driver doesn't support " - "setting video acceleration parameters.")); + _("vz driver doesn't support setting video acceleration parameters.")); return -1; } @@ -2759,15 +2741,13 @@ static int prlsdkCheckSerialUnsupportedParams(virDomainChrDef *chr) { if (chr->deviceType != VIR_DOMAIN_CHR_DEVICE_TYPE_SERIAL) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Specified character device type is not supported " - "by vz driver.")); + _("Specified character device type is not supported by vz driver.")); return -1; } if (chr->targetType != VIR_DOMAIN_CHR_SERIAL_TARGET_TYPE_NONE) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Specified character device target type is not " - "supported by vz driver.")); + _("Specified character device target type is not supported by vz driver.")); return -1; } @@ -2779,22 +2759,19 @@ static int prlsdkCheckSerialUnsupportedParams(virDomainChrDef *chr) virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Specified character device source type is not " - "supported by vz driver.")); + _("Specified character device source type is not supported by vz driver.")); return -1; } if (chr->info.type != VIR_DOMAIN_DEVICE_ADDRESS_TYPE_NONE) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Setting device info for character devices is not " - "supported by vz driver.")); + _("Setting device info for character devices is not supported by vz driver.")); return -1; } if (chr->source->nseclabels > 0) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Setting security labels is not " - "supported by vz driver.")); + _("Setting security labels is not supported by vz driver.")); return -1; } @@ -2812,8 +2789,7 @@ static int prlsdkCheckSerialUnsupportedParams(virDomainChrDef *chr) STRNEQ(chr->source->data.udp.bindService, chr->source->data.udp.connectService))) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Different bind and connect parameters for " - "udp character device is not supported.")); + _("Different bind and connect parameters for udp character device is not supported.")); return -1; } @@ -2825,71 +2801,61 @@ static int prlsdkCheckNetUnsupportedParams(virDomainNetDef *net) if (net->type != VIR_DOMAIN_NET_TYPE_NETWORK && net->type != VIR_DOMAIN_NET_TYPE_BRIDGE) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Specified network adapter type is not " - "supported by vz driver.")); + _("Specified network adapter type is not supported by vz driver.")); return -1; } if (net->backend.tap || net->backend.vhost) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Interface backend parameters are not " - "supported by vz driver.")); + _("Interface backend parameters are not supported by vz driver.")); return -1; } if (net->data.network.portgroup) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Virtual network portgroups are not " - "supported by vz driver.")); + _("Virtual network portgroups are not supported by vz driver.")); return -1; } if (net->tune.sndbuf_specified) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Setting interface sndbuf is not " - "supported by vz driver.")); + _("Setting interface sndbuf is not supported by vz driver.")); return -1; } if (net->script) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Setting interface script is not " - "supported by vz driver.")); + _("Setting interface script is not supported by vz driver.")); return -1; } if (net->ifname_guest) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Setting guest interface name is not " - "supported by vz driver.")); + _("Setting guest interface name is not supported by vz driver.")); return -1; } if (net->info.type != VIR_DOMAIN_DEVICE_ADDRESS_TYPE_NONE) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Setting device info for network devices is not " - "supported by vz driver.")); + _("Setting device info for network devices is not supported by vz driver.")); return -1; } if (net->filter) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Setting network filter is not " - "supported by vz driver.")); + _("Setting network filter is not supported by vz driver.")); return -1; } if (net->bandwidth) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Setting network bandwidth is not " - "supported by vz driver.")); + _("Setting network bandwidth is not supported by vz driver.")); return -1; } if (net->vlan.trunk) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Setting up vlans is not " - "supported by vz driver.")); + _("Setting up vlans is not supported by vz driver.")); return -1; } @@ -2901,50 +2867,43 @@ static int prlsdkCheckFSUnsupportedParams(virDomainFSDef *fs) if (fs->type != VIR_DOMAIN_FS_TYPE_FILE && fs->type != VIR_DOMAIN_FS_TYPE_VOLUME) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Only file based or volume based filesystems " - "are supported by vz driver.")); + _("Only file based or volume based filesystems are supported by vz driver.")); return -1; } if (fs->fsdriver != VIR_DOMAIN_FS_DRIVER_TYPE_PLOOP) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Only ploop fs driver is " - "supported by vz driver.")); + _("Only ploop fs driver is supported by vz driver.")); return -1; } if (fs->accessmode != VIR_DOMAIN_FS_ACCESSMODE_PASSTHROUGH) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Changing fs access mode is not " - "supported by vz driver.")); + _("Changing fs access mode is not supported by vz driver.")); return -1; } if (fs->wrpolicy != VIR_DOMAIN_FS_WRPOLICY_DEFAULT) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Changing fs write policy is not " - "supported by vz driver.")); + _("Changing fs write policy is not supported by vz driver.")); return -1; } if (fs->format != VIR_STORAGE_FILE_PLOOP) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Only ploop disk images are " - "supported by vz driver.")); + _("Only ploop disk images are supported by vz driver.")); return -1; } if (fs->readonly) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Setting readonly for filesystems is " - "not supported by vz driver.")); + _("Setting readonly for filesystems is not supported by vz driver.")); return -1; } if (fs->space_hard_limit || fs->space_soft_limit) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Setting fs quotas is not " - "supported by vz driver.")); + _("Setting fs quotas is not supported by vz driver.")); return -1; } @@ -3053,8 +3012,7 @@ static int prlsdkAddSerial(PRL_HANDLE sdkdom, virDomainChrDef *chr) break; default: virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("vz driver doesn't support " - "specified serial source type.")); + _("vz driver doesn't support specified serial source type.")); goto cleanup; } @@ -3280,8 +3238,7 @@ static int prlsdkConfigureNet(struct _vzDriver *driver G_GNUC_UNUSED, pret = PrlVmDevNet_SetAdapterType(sdknet, PNT_VIRTIO); } else { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Specified network adapter model is not " - "supported by vz driver.")); + _("Specified network adapter model is not supported by vz driver.")); goto cleanup; } prlsdkCheckRetGoto(pret, cleanup); @@ -3434,8 +3391,7 @@ static int prlsdkConfigureDisk(struct _vzDriver *driver, case VIR_DOMAIN_DISK_BUS_LAST: default: virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Specified disk bus is not " - "supported by vz driver.")); + _("Specified disk bus is not supported by vz driver.")); goto cleanup; } @@ -4276,8 +4232,7 @@ prlsdkUnregisterDomain(struct _vzDriver *driver, virDomainObj *dom, unsigned int !(flags & VIR_DOMAIN_UNDEFINE_MANAGED_SAVE)) { virReportError(VIR_ERR_OPERATION_INVALID, "%s", - _("Refusing to undefine while domain managed " - "save image exists")); + _("Refusing to undefine while domain managed save image exists")); return -1; } diff --git a/src/vz/vz_utils.c b/src/vz/vz_utils.c index 7db7dbd419..be1879a58b 100644 --- a/src/vz/vz_utils.c +++ b/src/vz/vz_utils.c @@ -273,16 +273,14 @@ vzCheckDiskUnsupportedParams(virDomainDiskDef *disk) disk->device != VIR_DOMAIN_DISK_DEVICE_CDROM) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Only hard disks and cdroms are supported " - "by vz driver.")); + _("Only hard disks and cdroms are supported by vz driver.")); return -1; } if (disk->blockio.logical_block_size || disk->blockio.physical_block_size) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Setting disk block sizes is not " - "supported by vz driver.")); + _("Setting disk block sizes is not supported by vz driver.")); return -1; } @@ -294,56 +292,48 @@ vzCheckDiskUnsupportedParams(virDomainDiskDef *disk) disk->blkdeviotune.write_iops_sec) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Setting disk io limits is not " - "supported by vz driver yet.")); + _("Setting disk io limits is not supported by vz driver yet.")); return -1; } if (disk->serial && disk->device != VIR_DOMAIN_DISK_DEVICE_DISK) { - VIR_INFO("%s", _("Setting disk serial number is " - "supported only for disk devices.")); + VIR_INFO("%s", _("Setting disk serial number is supported only for disk devices.")); } if (disk->wwn) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Setting disk wwn id is not " - "supported by vz driver.")); + _("Setting disk wwn id is not supported by vz driver.")); return -1; } if (disk->vendor) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Setting disk vendor is not " - "supported by vz driver.")); + _("Setting disk vendor is not supported by vz driver.")); return -1; } if (disk->product) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Setting disk product id is not " - "supported by vz driver.")); + _("Setting disk product id is not supported by vz driver.")); return -1; } if (disk->error_policy != VIR_DOMAIN_DISK_ERROR_POLICY_DEFAULT) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Setting disk error policy is not " - "supported by vz driver.")); + _("Setting disk error policy is not supported by vz driver.")); return -1; } if (disk->iomode != VIR_DOMAIN_DISK_IO_DEFAULT && disk->iomode != VIR_DOMAIN_DISK_IO_NATIVE) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Only native iomode is " - "supported by vz driver.")); + _("Only native iomode is supported by vz driver.")); return -1; } if (disk->copy_on_read) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Disk copy_on_read is not " - "supported by vz driver.")); + _("Disk copy_on_read is not supported by vz driver.")); return -1; } @@ -355,29 +345,25 @@ vzCheckDiskUnsupportedParams(virDomainDiskDef *disk) if (disk->startupPolicy != VIR_DOMAIN_STARTUP_POLICY_DEFAULT) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Setting up disk startup policy is not " - "supported by vz driver.")); + _("Setting up disk startup policy is not supported by vz driver.")); return -1; } if (disk->transient) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Transient disks are not " - "supported by vz driver.")); + _("Transient disks are not supported by vz driver.")); return -1; } if (disk->discard) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Setting up disk discard parameter is not " - "supported by vz driver.")); + _("Setting up disk discard parameter is not supported by vz driver.")); return -1; } if (disk->iothread) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Setting up disk io thread # is not " - "supported by vz driver.")); + _("Setting up disk io thread # is not supported by vz driver.")); return -1; } @@ -385,8 +371,7 @@ vzCheckDiskUnsupportedParams(virDomainDiskDef *disk) disk->src->type != VIR_STORAGE_TYPE_BLOCK) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("Only disk and block storage types are " - "supported by vz driver.")); + _("Only disk and block storage types are supported by vz driver.")); return -1; } @@ -503,52 +488,45 @@ int vzCheckUnsupportedGraphics(virDomainGraphicsDef *gr) { if (gr->type != VIR_DOMAIN_GRAPHICS_TYPE_VNC) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("vz driver supports only " - "VNC graphics.")); + _("vz driver supports only VNC graphics.")); return -1; } if (gr->data.vnc.websocket != 0) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("vz driver doesn't support " - "websockets for VNC graphics.")); + _("vz driver doesn't support websockets for VNC graphics.")); return -1; } if (gr->data.vnc.keymap != 0 && STRNEQ(gr->data.vnc.keymap, "en-us")) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("vz driver supports only " - "\"en-us\" keymap for VNC graphics.")); + _("vz driver supports only \"en-us\" keymap for VNC graphics.")); return -1; } if (gr->data.vnc.sharePolicy == VIR_DOMAIN_GRAPHICS_VNC_SHARE_ALLOW_EXCLUSIVE) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("vz driver doesn't support " - "exclusive share policy for VNC graphics.")); + _("vz driver doesn't support exclusive share policy for VNC graphics.")); return -1; } if (gr->data.vnc.auth.connected == VIR_DOMAIN_GRAPHICS_AUTH_CONNECTED_FAIL || gr->data.vnc.auth.connected == VIR_DOMAIN_GRAPHICS_AUTH_CONNECTED_KEEP) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("vz driver doesn't support " - "given action in case of password change.")); + _("vz driver doesn't support given action in case of password change.")); return -1; } if (gr->data.vnc.auth.expires) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s", - _("vz driver doesn't support " - "setting password expire time.")); + _("vz driver doesn't support setting password expire time.")); return -1; } if (gr->nListens > 1) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("vz driver doesn't support more than " - "one listening VNC server per domain")); + _("vz driver doesn't support more than one listening VNC server per domain")); return -1; } -- 2.41.0

Error messages are exempt from the 80 columns rule. Move them onto one line. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- src/libvirt-domain.c | 54 +++++++++++++++----------------------------- 1 file changed, 18 insertions(+), 36 deletions(-) diff --git a/src/libvirt-domain.c b/src/libvirt-domain.c index ec42bb9a53..6616294fc1 100644 --- a/src/libvirt-domain.c +++ b/src/libvirt-domain.c @@ -3569,8 +3569,7 @@ virDomainMigrateUnmanagedProto2(virDomainPtr domain, if (!virTypedParamsCheck(params, nparams, compatParams, G_N_ELEMENTS(compatParams))) { virReportError(VIR_ERR_ARGUMENT_UNSUPPORTED, "%s", - _("Some parameters are not supported by migration " - "protocol 2")); + _("Some parameters are not supported by migration protocol 2")); return -1; } @@ -3618,8 +3617,7 @@ virDomainMigrateUnmanagedProto3(virDomainPtr domain, if (!virTypedParamsCheck(params, nparams, compatParams, G_N_ELEMENTS(compatParams))) { virReportError(VIR_ERR_ARGUMENT_UNSUPPORTED, "%s", - _("Some parameters are not supported by migration " - "protocol 3")); + _("Some parameters are not supported by migration protocol 3")); return -1; } @@ -3822,8 +3820,7 @@ virDomainMigrate(virDomainPtr domain, if (rc <= 0) { if (rc == 0) virReportError(VIR_ERR_ARGUMENT_UNSUPPORTED, "%s", - _("offline migration is not supported by " - "the source host")); + _("offline migration is not supported by the source host")); goto error; } @@ -3832,8 +3829,7 @@ virDomainMigrate(virDomainPtr domain, if (rc <= 0) { if (rc == 0) virReportError(VIR_ERR_ARGUMENT_UNSUPPORTED, "%s", - _("offline migration is not supported by " - "the destination host")); + _("offline migration is not supported by the destination host")); goto error; } } @@ -4021,8 +4017,7 @@ virDomainMigrate2(virDomainPtr domain, if (rc <= 0) { if (rc == 0) virReportError(VIR_ERR_ARGUMENT_UNSUPPORTED, "%s", - _("offline migration is not supported by " - "the source host")); + _("offline migration is not supported by the source host")); goto error; } rc = VIR_DRV_SUPPORTS_FEATURE(dconn->driver, dconn, @@ -4030,8 +4025,7 @@ virDomainMigrate2(virDomainPtr domain, if (rc <= 0) { if (rc == 0) virReportError(VIR_ERR_ARGUMENT_UNSUPPORTED, "%s", - _("offline migration is not supported by " - "the destination host")); + _("offline migration is not supported by the destination host")); goto error; } } @@ -4233,14 +4227,12 @@ virDomainMigrate3(virDomainPtr domain, if (flags & VIR_MIGRATE_PEER2PEER) { virReportInvalidArg(flags, "%s", - _("use virDomainMigrateToURI3 for peer-to-peer " - "migration")); + _("use virDomainMigrateToURI3 for peer-to-peer migration")); goto error; } if (flags & VIR_MIGRATE_TUNNELLED) { virReportInvalidArg(flags, "%s", - _("cannot perform tunnelled migration " - "without using peer2peer flag")); + _("cannot perform tunnelled migration without using peer2peer flag")); goto error; } @@ -4250,8 +4242,7 @@ virDomainMigrate3(virDomainPtr domain, if (rc <= 0) { if (rc == 0) virReportError(VIR_ERR_ARGUMENT_UNSUPPORTED, "%s", - _("offline migration is not supported by " - "the source host")); + _("offline migration is not supported by the source host")); goto error; } @@ -4260,8 +4251,7 @@ virDomainMigrate3(virDomainPtr domain, if (rc <= 0) { if (rc == 0) virReportError(VIR_ERR_ARGUMENT_UNSUPPORTED, "%s", - _("offline migration is not supported by " - "the destination host")); + _("offline migration is not supported by the destination host")); goto error; } } @@ -4303,8 +4293,7 @@ virDomainMigrate3(virDomainPtr domain, if (!virTypedParamsCheck(params, nparams, compatParams, G_N_ELEMENTS(compatParams))) { virReportError(VIR_ERR_ARGUMENT_UNSUPPORTED, "%s", - _("Migration APIs with extensible parameters are not " - "supported but extended parameters were passed")); + _("Migration APIs with extensible parameters are not supported but extended parameters were passed")); goto error; } @@ -4346,8 +4335,7 @@ virDomainMigrate3(virDomainPtr domain, VIR_DEBUG("Using migration protocol 2"); if (dxml) { virReportError(VIR_ERR_ARGUMENT_UNSUPPORTED, "%s", - _("Unable to change target guest XML during " - "migration")); + _("Unable to change target guest XML during migration")); goto error; } ddomain = virDomainMigrateVersion2(domain, dconn, flags, @@ -4367,8 +4355,7 @@ virDomainMigrate3(virDomainPtr domain, VIR_DEBUG("Using migration protocol 1"); if (dxml) { virReportError(VIR_ERR_ARGUMENT_UNSUPPORTED, "%s", - _("Unable to change target guest XML during " - "migration")); + _("Unable to change target guest XML during migration")); goto error; } ddomain = virDomainMigrateVersion1(domain, dconn, flags, @@ -4413,8 +4400,7 @@ int virDomainMigrateUnmanagedCheckCompat(virDomainPtr domain, if (rc <= 0) { if (rc == 0) virReportError(VIR_ERR_ARGUMENT_UNSUPPORTED, "%s", - _("offline migration is not supported by " - "the source host")); + _("offline migration is not supported by the source host")); return -1; } } @@ -4426,8 +4412,7 @@ int virDomainMigrateUnmanagedCheckCompat(virDomainPtr domain, if (rc <= 0) { if (rc == 0) virReportError(VIR_ERR_ARGUMENT_UNSUPPORTED, "%s", - _("p2p migration is not supported by " - "the source host")); + _("p2p migration is not supported by the source host")); return -1; } } else { @@ -4436,8 +4421,7 @@ int virDomainMigrateUnmanagedCheckCompat(virDomainPtr domain, if (rc <= 0) { if (rc == 0) virReportError(VIR_ERR_ARGUMENT_UNSUPPORTED, "%s", - _("direct migration is not supported by " - "the source host")); + _("direct migration is not supported by the source host")); return -1; } } @@ -8585,8 +8569,7 @@ virDomainSetMetadata(virDomainPtr domain, case VIR_DOMAIN_METADATA_TITLE: if (metadata && strchr(metadata, '\n')) { virReportInvalidArg(metadata, "%s", - _("metadata title can't contain " - "newlines")); + _("metadata title can't contain newlines")); goto error; } G_GNUC_FALLTHROUGH; @@ -12697,8 +12680,7 @@ virDomainListGetStats(virDomainPtr *doms, if (dom->conn != conn) { virReportError(VIR_ERR_INVALID_ARG, "%s", - _("domains in 'doms' array must belong to a " - "single connection")); + _("domains in 'doms' array must belong to a single connection")); goto cleanup; } -- 2.41.0

Error messages are exempt from the 80 columns rule. Move them onto one line. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> --- tools/virsh-domain-event.c | 15 +++++--------- tools/virsh-domain.c | 36 +++++++++++---------------------- tools/virsh-host.c | 9 +++------ tools/virsh-network.c | 6 ++---- tools/virsh-nodedev.c | 3 +-- tools/virsh-pool.c | 3 +-- tools/virsh.c | 9 +++------ tools/virt-admin.c | 21 +++++++------------ tools/virt-host-validate-ch.c | 12 ++++------- tools/virt-host-validate-qemu.c | 15 +++++--------- tools/vsh.c | 12 ++++------- 11 files changed, 47 insertions(+), 94 deletions(-) diff --git a/tools/virsh-domain-event.c b/tools/virsh-domain-event.c index 2969c22a91..6887c195a0 100644 --- a/tools/virsh-domain-event.c +++ b/tools/virsh-domain-event.c @@ -418,8 +418,7 @@ virshEventGraphicsPrint(virConnectPtr conn G_GNUC_UNUSED, g_auto(virBuffer) buf = VIR_BUFFER_INITIALIZER; size_t i; - virBufferAsprintf(&buf, _("event 'graphics' for domain '%1$s': " - "%2$s local[%3$s %4$s %5$s] remote[%6$s %7$s %8$s] %9$s\n"), + virBufferAsprintf(&buf, _("event 'graphics' for domain '%1$s': %2$s local[%3$s %4$s %5$s] remote[%6$s %7$s %8$s] %9$s\n"), virDomainGetName(dom), virshGraphicsPhaseToString(phase), virshGraphicsAddressToString(local->family), @@ -497,8 +496,7 @@ virshEventDiskChangePrint(virConnectPtr conn G_GNUC_UNUSED, { g_auto(virBuffer) buf = VIR_BUFFER_INITIALIZER; - virBufferAsprintf(&buf, _("event 'disk-change' for domain '%1$s' disk %2$s: " - "%3$s -> %4$s: %5$s\n"), + virBufferAsprintf(&buf, _("event 'disk-change' for domain '%1$s' disk %2$s: %3$s -> %4$s: %5$s\n"), virDomainGetName(dom), alias, NULLSTR(oldSrc), @@ -633,8 +631,7 @@ virshEventAgentLifecyclePrint(virConnectPtr conn G_GNUC_UNUSED, { g_auto(virBuffer) buf = VIR_BUFFER_INITIALIZER; - virBufferAsprintf(&buf, _("event 'agent-lifecycle' for domain '%1$s': state: " - "'%2$s' reason: '%3$s'\n"), + virBufferAsprintf(&buf, _("event 'agent-lifecycle' for domain '%1$s': state: '%2$s' reason: '%3$s'\n"), virDomainGetName(dom), UNKNOWNSTR(virshEventAgentLifecycleStateTypeToString(state)), UNKNOWNSTR(virshEventAgentLifecycleReasonTypeToString(reason))); @@ -649,8 +646,7 @@ virshEventMigrationIterationPrint(virConnectPtr conn G_GNUC_UNUSED, { g_auto(virBuffer) buf = VIR_BUFFER_INITIALIZER; - virBufferAsprintf(&buf, _("event 'migration-iteration' for domain '%1$s': " - "iteration: '%2$d'\n"), + virBufferAsprintf(&buf, _("event 'migration-iteration' for domain '%1$s': iteration: '%2$d'\n"), virDomainGetName(dom), iteration); @@ -727,8 +723,7 @@ virshEventBlockThresholdPrint(virConnectPtr conn G_GNUC_UNUSED, { g_auto(virBuffer) buf = VIR_BUFFER_INITIALIZER; - virBufferAsprintf(&buf, _("event 'block-threshold' for domain '%1$s': " - "dev: %2$s(%3$s) %4$llu %5$llu\n"), + virBufferAsprintf(&buf, _("event 'block-threshold' for domain '%1$s': dev: %2$s(%3$s) %4$llu %5$llu\n"), virDomainGetName(dom), dev, NULLSTR(path), threshold, excess); virshEventPrint(opaque, &buf); diff --git a/tools/virsh-domain.c b/tools/virsh-domain.c index e0776c991f..7250c1989e 100644 --- a/tools/virsh-domain.c +++ b/tools/virsh-domain.c @@ -2143,14 +2143,12 @@ cmdBlockcommit(vshControl *ctl, const vshCmd *cmd) if (!blocking) { if (verbose) { - vshError(ctl, "%s", _("--verbose requires at least one of --timeout, " - "--wait, --pivot, or --keep-overlay")); + vshError(ctl, "%s", _("--verbose requires at least one of --timeout, --wait, --pivot, or --keep-overlay")); return false; } if (async) { - vshError(ctl, "%s", _("--async requires at least one of --timeout, " - "--wait, --pivot, or --keep-overlay")); + vshError(ctl, "%s", _("--async requires at least one of --timeout, --wait, --pivot, or --keep-overlay")); return false; } } @@ -2214,8 +2212,7 @@ cmdBlockcommit(vshControl *ctl, const vshCmd *cmd) goto cleanup; } - vshPrintExtra(ctl, "\n%s", _("Commit complete, overlay " - "image kept")); + vshPrintExtra(ctl, "\n%s", _("Commit complete, overlay image kept")); } else { vshPrintExtra(ctl, "\n%s", _("Now in synchronized phase")); } @@ -2411,14 +2408,12 @@ cmdBlockcopy(vshControl *ctl, const vshCmd *cmd) if (!blocking) { if (verbose) { - vshError(ctl, "%s", _("--verbose requires at least one of --timeout, " - "--wait, --pivot, or --finish")); + vshError(ctl, "%s", _("--verbose requires at least one of --timeout, --wait, --pivot, or --finish")); return false; } if (async) { - vshError(ctl, "%s", _("--async requires at least one of --timeout, " - "--wait, --pivot, or --finish")); + vshError(ctl, "%s", _("--async requires at least one of --timeout, --wait, --pivot, or --finish")); return false; } } @@ -3703,8 +3698,7 @@ cmdUndefine(vshControl *ctl, const vshCmd *cmd) if (!(vol_string || remove_all_storage) && wipe_storage) { vshError(ctl, - _("'--wipe-storage' requires '--storage <string>' or " - "'--remove-all-storage'")); + _("'--wipe-storage' requires '--storage <string>' or '--remove-all-storage'")); return false; } @@ -3789,8 +3783,7 @@ cmdUndefine(vshControl *ctl, const vshCmd *cmd) if (vol_string || remove_all_storage) { if (running) { vshError(ctl, - _("Storage volume deletion is supported only on " - "stopped domains")); + _("Storage volume deletion is supported only on stopped domains")); goto cleanup; } @@ -3927,8 +3920,7 @@ cmdUndefine(vshControl *ctl, const vshCmd *cmd) if (has_managed_save) { if (!managed_save) { vshError(ctl, "%s", - _("Refusing to undefine while domain managed save " - "image exists")); + _("Refusing to undefine while domain managed save image exists")); goto cleanup; } if (virDomainManagedSaveRemove(dom, 0) < 0) { @@ -5149,8 +5141,7 @@ cmdSchedInfoUpdate(vshControl *ctl, const vshCmd *cmd, g_autofree char *set_field = g_strdup(opt->data); if (!(set_val = strchr(set_field, '='))) { - vshError(ctl, "%s", _("Invalid syntax for --set, " - "expecting name=value")); + vshError(ctl, "%s", _("Invalid syntax for --set, expecting name=value")); goto cleanup; } @@ -7400,8 +7391,7 @@ cmdGuestvcpus(vshControl *ctl, const vshCmd *cmd) return false; if (cpulist && !(enable || disable)) { - vshError(ctl, _("One of options --enable or --disable is required by " - "option --cpulist")); + vshError(ctl, _("One of options --enable or --disable is required by option --cpulist")); return false; } @@ -12528,8 +12518,7 @@ virshDomainDetachInterface(char *doc, if (virMacAddrCompare(tmp_mac, mac) == 0) { if (matchNode) { /* this is the 2nd match, so it's ambiguous */ - vshError(ctl, _("Domain has multiple interfaces matching MAC address %1$s. " - "You must use detach-device and specify the device pci address to remove it."), + vshError(ctl, _("Domain has multiple interfaces matching MAC address %1$s. You must use detach-device and specify the device pci address to remove it."), mac); return false; } @@ -13787,8 +13776,7 @@ cmdDomDirtyRateCalc(vshControl *ctl, const vshCmd *cmd) if (virDomainStartDirtyRateCalc(dom, seconds, flags) < 0) return false; - vshPrintExtra(ctl, _("Start to calculate domain's memory " - "dirty rate successfully.\n")); + vshPrintExtra(ctl, _("Start to calculate domain's memory dirty rate successfully.\n")); return true; } diff --git a/tools/virsh-host.c b/tools/virsh-host.c index ad440d5123..21aca5f6dc 100644 --- a/tools/virsh-host.c +++ b/tools/virsh-host.c @@ -355,8 +355,7 @@ cmdFreepages(vshControl *ctl, const vshCmd *cmd) nodes_cnt = virXPathNodeSet("/capabilities/host/topology/cells/cell/pages", ctxt, &nodes); if (nodes_cnt <= 0) { - vshError(ctl, "%s", _("could not get information about " - "supported page sizes")); + vshError(ctl, "%s", _("could not get information about supported page sizes")); goto cleanup; } } @@ -548,8 +547,7 @@ cmdAllocpages(vshControl *ctl, const vshCmd *cmd) ctxt, &nodes); if (nodes_cnt == -1) { - vshError(ctl, "%s", _("could not get information about " - "NUMA topology")); + vshError(ctl, "%s", _("could not get information about NUMA topology")); return false; } @@ -1180,8 +1178,7 @@ vshExtractCPUDefXMLs(vshControl *ctl, while (nodes[i]->properties) { if (xmlRemoveProp(nodes[i]->properties) < 0) { vshError(ctl, - _("Cannot extract CPU definition from domain " - "capabilities XML")); + _("Cannot extract CPU definition from domain capabilities XML")); return NULL; } } diff --git a/tools/virsh-network.c b/tools/virsh-network.c index 42b7dba761..11e927d3ff 100644 --- a/tools/virsh-network.c +++ b/tools/virsh-network.c @@ -742,8 +742,7 @@ cmdNetworkList(vshControl *ctl, const vshCmd *cmd G_GNUC_UNUSED) if (optTable + optName + optUUID > 1) { vshError(ctl, "%s", - _("Only one argument from --table, --name and --uuid " - "may be specified.")); + _("Only one argument from --table, --name and --uuid may be specified.")); return false; } @@ -1764,8 +1763,7 @@ cmdNetworkPortList(vshControl *ctl, const vshCmd *cmd) if (optTable + optUUID > 1) { vshError(ctl, "%s", - _("Only one argument from --table and --uuid " - "may be specified.")); + _("Only one argument from --table and --uuid may be specified.")); return false; } diff --git a/tools/virsh-nodedev.c b/tools/virsh-nodedev.c index a079c8063b..82b8fb44fc 100644 --- a/tools/virsh-nodedev.c +++ b/tools/virsh-nodedev.c @@ -297,8 +297,7 @@ virshNodeDeviceListCollect(vshControl *ctl, device = list->devices[i]; if ((ncaps = virNodeDeviceNumOfCaps(device)) < 0) { - vshError(ctl, "%s", _("Failed to get capability numbers " - "of the device")); + vshError(ctl, "%s", _("Failed to get capability numbers of the device")); goto cleanup; } diff --git a/tools/virsh-pool.c b/tools/virsh-pool.c index 56bd414dc9..5803530d79 100644 --- a/tools/virsh-pool.c +++ b/tools/virsh-pool.c @@ -895,8 +895,7 @@ virshStoragePoolListCollect(vshControl *ctl, /* There is no way to get the pool type */ if (VSH_MATCH(VIR_CONNECT_LIST_STORAGE_POOLS_FILTERS_POOL_TYPE)) { - vshError(ctl, "%s", _("Filtering using --type is not supported " - "by this libvirt")); + vshError(ctl, "%s", _("Filtering using --type is not supported by this libvirt")); goto cleanup; } diff --git a/tools/virsh.c b/tools/virsh.c index 40c23e4180..d9922a35fc 100644 --- a/tools/virsh.c +++ b/tools/virsh.c @@ -166,8 +166,7 @@ virshConnect(vshControl *ctl, const char *uri, bool readonly) virConnectSetKeepAlive(c, interval, count) != 0) { if (keepalive_forced) { vshError(ctl, "%s", - _("Cannot setup keepalive on connection " - "as requested, disconnecting")); + _("Cannot setup keepalive on connection as requested, disconnecting")); g_clear_pointer(&c, virConnectClose); goto cleanup; } @@ -209,8 +208,7 @@ virshReconnect(vshControl *ctl, const char *name, bool readonly, bool force) if (ret < 0) vshError(ctl, "%s", _("Failed to disconnect from the hypervisor")); else if (ret > 0) - vshError(ctl, "%s", _("One or more references were leaked after " - "disconnect from the hypervisor")); + vshError(ctl, "%s", _("One or more references were leaked after disconnect from the hypervisor")); } priv->conn = virshConnect(ctl, name ? name : ctl->connname, readonly); @@ -400,8 +398,7 @@ virshDeinit(vshControl *ctl) if (ret < 0) vshError(ctl, "%s", _("Failed to disconnect from the hypervisor")); else if (ret > 0) - vshError(ctl, "%s", _("One or more references were leaked after " - "disconnect from the hypervisor")); + vshError(ctl, "%s", _("One or more references were leaked after disconnect from the hypervisor")); } virResetLastError(); diff --git a/tools/virt-admin.c b/tools/virt-admin.c index 9d01890447..15a639f1ea 100644 --- a/tools/virt-admin.c +++ b/tools/virt-admin.c @@ -139,8 +139,7 @@ vshAdmDisconnect(vshControl *ctl) if (ret < 0) vshError(ctl, "%s", _("Failed to disconnect from the admin server")); else if (ret > 0) - vshError(ctl, "%s", _("One or more references were leaked after " - "disconnect from the hypervisor")); + vshError(ctl, "%s", _("One or more references were leaked after disconnect from the hypervisor")); priv->conn = NULL; return ret; } @@ -500,8 +499,7 @@ cmdSrvThreadpoolSet(vshControl *ctl, const vshCmd *cmd) if (!nparams) { vshError(ctl, "%s", - _("At least one of options --min-workers, --max-workers, " - "--priority-workers is mandatory")); + _("At least one of options --min-workers, --max-workers, --priority-workers is mandatory")); goto cleanup; } @@ -509,8 +507,7 @@ cmdSrvThreadpoolSet(vshControl *ctl, const vshCmd *cmd) VIR_THREADPOOL_WORKERS_MAX, &max) && virTypedParamsGetUInt(params, nparams, VIR_THREADPOOL_WORKERS_MIN, &min) && min > max) { - vshError(ctl, "%s", _("--min-workers must be less than or equal to " - "--max-workers")); + vshError(ctl, "%s", _("--min-workers must be less than or equal to --max-workers")); goto cleanup; } @@ -820,8 +817,7 @@ cmdSrvClientsInfo(vshControl *ctl, const vshCmd *cmd) goto cleanup; if (virAdmServerGetClientLimits(srv, ¶ms, &nparams, 0) < 0) { - vshError(ctl, "%s", _("Unable to retrieve client limits " - "from server's configuration")); + vshError(ctl, "%s", _("Unable to retrieve client limits from server's configuration")); goto cleanup; } @@ -904,8 +900,7 @@ cmdSrvClientsSet(vshControl *ctl, const vshCmd *cmd) #undef PARSE_CMD_TYPED_PARAM if (!nparams) { - vshError(ctl, "%s", _("At least one of options --max-clients, " - "--max-unauth-clients is mandatory")); + vshError(ctl, "%s", _("At least one of options --max-clients, --max-unauth-clients is mandatory")); goto cleanup; } @@ -914,8 +909,7 @@ cmdSrvClientsSet(vshControl *ctl, const vshCmd *cmd) virTypedParamsGetUInt(params, nparams, VIR_SERVER_CLIENTS_UNAUTH_MAX, &unauth_max) && unauth_max > max) { - vshError(ctl, "%s", _("--max-unauth-clients must be less than or equal to " - "--max-clients")); + vshError(ctl, "%s", _("--max-unauth-clients must be less than or equal to --max-clients")); goto cleanup; } @@ -936,8 +930,7 @@ cmdSrvClientsSet(vshControl *ctl, const vshCmd *cmd) vshSaveLibvirtError(); error: - vshError(ctl, "%s", _("Unable to change server's client-related " - "configuration limits")); + vshError(ctl, "%s", _("Unable to change server's client-related configuration limits")); goto cleanup; } diff --git a/tools/virt-host-validate-ch.c b/tools/virt-host-validate-ch.c index b26f82738d..9d235ed7ab 100644 --- a/tools/virt-host-validate-ch.c +++ b/tools/virt-host-validate-ch.c @@ -33,8 +33,7 @@ int virHostValidateCh(void) bool hasVirtFlag = false; virArch arch = virArchFromHost(); const char *kvmhint = - _("Check that CPU and firmware supports virtualization " - "and kvm module is loaded"); + _("Check that CPU and firmware supports virtualization and kvm module is loaded"); if (!(flags = virHostValidateGetCPUFlags())) return -1; @@ -43,8 +42,7 @@ int virHostValidateCh(void) switch ((int)arch) { case VIR_ARCH_X86_64: hasVirtFlag = true; - kvmhint = _("Check that the 'kvm-intel' or 'kvm-amd' modules are " - "loaded & the BIOS has enabled virtualization"); + kvmhint = _("Check that the 'kvm-intel' or 'kvm-amd' modules are loaded & the BIOS has enabled virtualization"); if (virBitmapIsBitSet(flags, VIR_HOST_VALIDATE_CPU_FLAG_SVM) || virBitmapIsBitSet(flags, VIR_HOST_VALIDATE_CPU_FLAG_VMX)) hasHwVirt = true; @@ -64,8 +62,7 @@ int virHostValidateCh(void) virHostMsgPass(); } else { virHostMsgFail(VIR_HOST_VALIDATE_FAIL, - _("Only emulated CPUs are available, performance will be " - "significantly limited")); + _("Only emulated CPUs are available, performance will be significantly limited")); ret = -1; } } @@ -75,8 +72,7 @@ int virHostValidateCh(void) kvmhint) < 0) ret = -1; else if (virHostValidateDeviceAccessible("CH", "/dev/kvm", VIR_HOST_VALIDATE_FAIL, - _("Check /dev/kvm is world writable or you are in " - "a group that is allowed to access it")) < 0) + _("Check /dev/kvm is world writable or you are in a group that is allowed to access it")) < 0) ret = -1; } diff --git a/tools/virt-host-validate-qemu.c b/tools/virt-host-validate-qemu.c index 096419869c..3eeee516d3 100644 --- a/tools/virt-host-validate-qemu.c +++ b/tools/virt-host-validate-qemu.c @@ -34,8 +34,7 @@ int virHostValidateQEMU(void) bool hasHwVirt = false; bool hasVirtFlag = false; virArch arch = virArchFromHost(); - const char *kvmhint = _("Check that CPU and firmware supports virtualization " - "and kvm module is loaded"); + const char *kvmhint = _("Check that CPU and firmware supports virtualization and kvm module is loaded"); if (!(flags = virHostValidateGetCPUFlags())) return -1; @@ -44,8 +43,7 @@ int virHostValidateQEMU(void) case VIR_ARCH_I686: case VIR_ARCH_X86_64: hasVirtFlag = true; - kvmhint = _("Check that the 'kvm-intel' or 'kvm-amd' modules are " - "loaded & the BIOS has enabled virtualization"); + kvmhint = _("Check that the 'kvm-intel' or 'kvm-amd' modules are loaded & the BIOS has enabled virtualization"); if (virBitmapIsBitSet(flags, VIR_HOST_VALIDATE_CPU_FLAG_SVM) || virBitmapIsBitSet(flags, VIR_HOST_VALIDATE_CPU_FLAG_VMX)) hasHwVirt = true; @@ -71,8 +69,7 @@ int virHostValidateQEMU(void) virHostMsgPass(); } else { virHostMsgFail(VIR_HOST_VALIDATE_FAIL, - _("Host not compatible with KVM; HW virtualization CPU features not found. " - "Only emulated CPUs are available; performance will be significantly limited")); + _("Host not compatible with KVM; HW virtualization CPU features not found. Only emulated CPUs are available; performance will be significantly limited")); ret = -1; } } @@ -84,8 +81,7 @@ int virHostValidateQEMU(void) ret = -1; else if (virHostValidateDeviceAccessible("QEMU", "/dev/kvm", VIR_HOST_VALIDATE_FAIL, - _("Check /dev/kvm is world writable or you are in " - "a group that is allowed to access it")) < 0) + _("Check /dev/kvm is world writable or you are in a group that is allowed to access it")) < 0) ret = -1; } @@ -101,8 +97,7 @@ int virHostValidateQEMU(void) if (virHostValidateDeviceExists("QEMU", "/dev/vhost-net", VIR_HOST_VALIDATE_WARN, - _("Load the 'vhost_net' module to improve performance " - "of virtio networking")) < 0) + _("Load the 'vhost_net' module to improve performance of virtio networking")) < 0) ret = -1; if (virHostValidateDeviceExists("QEMU", "/dev/net/tun", diff --git a/tools/vsh.c b/tools/vsh.c index 41f55a91fa..65deaa77e8 100644 --- a/tools/vsh.c +++ b/tools/vsh.c @@ -2358,8 +2358,7 @@ vshAskReedit(vshControl *ctl, const char *msg, bool relax_avail) if (relax_avail) { vshPrintRaw(ctl, - _("i - turn off validation and try to redefine " - "again"), + _("i - turn off validation and try to redefine again"), NULL); } @@ -2385,8 +2384,7 @@ vshAskReedit(vshControl *ctl, const char *msg G_GNUC_UNUSED, bool relax_avail G_GNUC_UNUSED) { - vshDebug(ctl, VSH_ERR_WARNING, "%s", _("This function is not " - "supported on WIN32 platform")); + vshDebug(ctl, VSH_ERR_WARNING, "%s", _("This function is not supported on WIN32 platform")); return 0; } #endif /* WIN32 */ @@ -3022,8 +3020,7 @@ vshInit(vshControl *ctl, const vshCmdGrp *groups, const vshCmdDef *set) } if (!groups && !set) { - vshError(ctl, "%s", _("command groups and command set " - "cannot both be NULL")); + vshError(ctl, "%s", _("command groups and command set cannot both be NULL")); return false; } @@ -3041,8 +3038,7 @@ bool vshInitReload(vshControl *ctl) { if (!cmdGroups && !cmdSet) { - vshError(ctl, "%s", _("command groups and command are both NULL " - "run vshInit before reloading")); + vshError(ctl, "%s", _("command groups and command are both NULL run vshInit before reloading")); return false; } -- 2.41.0

On Fri, Aug 25, 2023 at 09:39:57AM +0200, Michal Privoznik wrote:
This is inspired by the following discussion:
https://listman.redhat.com/archives/libvir-list/2023-August/241361.html
We have it covered by coding style document so it would be nice to make a syntax-check for it as well so there are no new multi-line errors introduced in the future. Not sure how difficult it would be so definitely as follow up. Otherwise looks good and compiles without issues on my machine. I would consider pushing it after release is done to make sure it will not break anything as it affects basically the whole libvirt code base.
And ideally I'd present a green pipeline but for some reason, I can't:
https://gitlab.com/MichalPrivoznik/libvirt/-/pipelines/981105262
But the problem is not with my code rather than our CI.
Unless there are objections from others Reviewed-by: Pavel Hrdina <phrdina@redhat.com>

On 8/25/23 12:14, Pavel Hrdina wrote:
On Fri, Aug 25, 2023 at 09:39:57AM +0200, Michal Privoznik wrote:
This is inspired by the following discussion:
https://listman.redhat.com/archives/libvir-list/2023-August/241361.html
We have it covered by coding style document so it would be nice to make a syntax-check for it as well so there are no new multi-line errors introduced in the future. Not sure how difficult it would be so definitely as follow up.
Yeah, I was thinking about that, but I'm not that good with RE-s.
Otherwise looks good and compiles without issues on my machine.
I would consider pushing it after release is done to make sure it will not break anything as it affects basically the whole libvirt code base.
I hear you and I agree. And given how huge the change is I'd rather push it right after the release to avoid any conflicts.
And ideally I'd present a green pipeline but for some reason, I can't:
https://gitlab.com/MichalPrivoznik/libvirt/-/pipelines/981105262
But the problem is not with my code rather than our CI.
Unless there are objections from others
Reviewed-by: Pavel Hrdina <phrdina@redhat.com>
Thank you! Michal
participants (3)
-
Michal Privoznik
-
Michal Prívozník
-
Pavel Hrdina