!(datastoreName = strtok_r(tmp, "/", &saveptr)) ||
!(directoryAndFileName = strtok_r(NULL, "", &saveptr))) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("File name '%s' doesn't have expected format "
- "'/vmfs/volumes/<datastore>/<path>'"), fileName);
+ _("File name '%1$s' doesn't have expected format '/vmfs/volumes/<datastore>/<path>'"),
+ fileName);
goto cleanup;
}
ret = 0;
} else {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("File name '%s' refers to non-existing datastore '%s'"),
+ _("File name '%1$s' refers to non-existing datastore '%2$s'"),
fileName, datastoreName);
}
goto cleanup;
if (!*out) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not handle file name '%s'"), fileName);
+ _("Could not handle file name '%1$s'"), fileName);
goto cleanup;
}
tmpResult = g_strdup(fileName);
} else {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not handle file name '%s'"), fileName);
+ _("Could not handle file name '%1$s'"), fileName);
goto cleanup;
}
if (!vmDiskFileInfo || !vmDiskFileInfo->controllerType) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not lookup controller model for '%s'"), src);
+ _("Could not lookup controller model for '%1$s'"), src);
goto cleanup;
}
*model = VIR_DOMAIN_CONTROLLER_MODEL_SCSI_VMPVSCSI;
} else {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Found unexpected controller model '%s' for disk '%s'"),
+ _("Found unexpected controller model '%1$s' for disk '%2$s'"),
vmDiskFileInfo->controllerType, src);
goto cleanup;
}
priv->supportsLongMode = esxVI_Boolean_False;
} else {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Bit 29 (Long Mode) of HostSystem property "
- "'hardware.cpuFeature[].edx' with value '%s' "
- "has unexpected value '%c', expecting '0' "
- "or '1'"), hostCpuIdInfo->edx, edxLongModeBit);
+ _("Bit 29 (Long Mode) of HostSystem property 'hardware.cpuFeature[].edx' with value '%1$s' has unexpected value '%2$c', expecting '0' or '1'"),
+ hostCpuIdInfo->edx, edxLongModeBit);
goto cleanup;
}
if (priv->host->productLine != expectedProductLine) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Expecting '%s' to be a %s host but found a %s host"),
+ _("Expecting '%1$s' to be a %2$s host but found a %3$s host"),
conn->uri->server,
esxVI_ProductLineToDisplayName(expectedProductLine),
esxVI_ProductLineToDisplayName(priv->host->productLine));
if (priv->vCenter->productLine != esxVI_ProductLine_VPX) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Expecting '%s' to be a %s host but found a %s host"),
+ _("Expecting '%1$s' to be a %2$s host but found a %3$s host"),
hostname,
esxVI_ProductLineToDisplayName(esxVI_ProductLine_VPX),
esxVI_ProductLineToDisplayName(priv->vCenter->productLine));
if (potentialVCenterIPAddress &&
STRNEQ(vCenterIPAddress, potentialVCenterIPAddress)) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("This host is managed by a vCenter with IP "
- "address %s, but a mismatching vCenter '%s' "
- "(%s) has been specified"),
+ _("This host is managed by a vCenter with IP address %1$s, but a mismatching vCenter '%2$s' (%3$s) has been specified"),
potentialVCenterIPAddress, priv->parsedUri->vCenter,
vCenterIPAddress);
goto cleanup;
case VIR_DRV_FEATURE_NETWORK_UPDATE_HAS_CORRECT_ORDER:
case VIR_DRV_FEATURE_FD_PASSING:
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
- _("Global feature %d should have already been handled"),
+ _("Global feature %1$d should have already been handled"),
feature);
return -1;
dynamicProperty->val->string[sizeof(nodeinfo->model) - 1] = '\0';
if (virStrcpyStatic(nodeinfo->model, dynamicProperty->val->string) < 0) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("CPU Model %s too long for destination"),
+ _("CPU Model %1$s too long for destination"),
dynamicProperty->val->string);
goto cleanup;
}
&ids[count]) < 0 ||
ids[count] <= 0) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Failed to parse positive integer from '%s'"),
+ _("Failed to parse positive integer from '%1$s'"),
virtualMachine->obj->value);
goto cleanup;
}
}
if (!domain)
- virReportError(VIR_ERR_NO_DOMAIN, _("No domain with ID %d"), id);
+ virReportError(VIR_ERR_NO_DOMAIN, _("No domain with ID %1$d"), id);
cleanup:
esxVI_String_Free(&propertyNameList);
}
if (taskInfoState != esxVI_TaskInfoState_Success) {
- virReportError(VIR_ERR_INTERNAL_ERROR, _("Could not suspend domain: %s"),
+ virReportError(VIR_ERR_INTERNAL_ERROR, _("Could not suspend domain: %1$s"),
taskInfoErrorMessage);
goto cleanup;
}
}
if (taskInfoState != esxVI_TaskInfoState_Success) {
- virReportError(VIR_ERR_INTERNAL_ERROR, _("Could not resume domain: %s"),
+ virReportError(VIR_ERR_INTERNAL_ERROR, _("Could not resume domain: %1$s"),
taskInfoErrorMessage);
goto cleanup;
}
}
if (taskInfoState != esxVI_TaskInfoState_Success) {
- virReportError(VIR_ERR_INTERNAL_ERROR, _("Could not destroy domain: %s"),
+ virReportError(VIR_ERR_INTERNAL_ERROR, _("Could not destroy domain: %1$s"),
taskInfoErrorMessage);
goto cleanup;
}
if (dynamicProperty->val->int32 < 0) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Got invalid memory size %d"),
+ _("Got invalid memory size %1$d"),
dynamicProperty->val->int32);
} else {
memoryMB = dynamicProperty->val->int32;
if (taskInfoState != esxVI_TaskInfoState_Success) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not set max-memory to %lu kilobytes: %s"), memory,
+ _("Could not set max-memory to %1$lu kilobytes: %2$s"), memory,
taskInfoErrorMessage);
goto cleanup;
}
if (taskInfoState != esxVI_TaskInfoState_Success) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not set memory to %lu kilobytes: %s"), memory,
+ _("Could not set memory to %1$lu kilobytes: %2$s"), memory,
taskInfoErrorMessage);
goto cleanup;
}
if (!perfEntityMetric) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("QueryPerf returned object with unexpected type '%s'"),
+ _("QueryPerf returned object with unexpected type '%1$s'"),
esxVI_Type_ToString(perfEntityMetricBase->_type));
goto cleanup;
}
if (!perfMetricIntSeries) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("QueryPerf returned object with unexpected type '%s'"),
+ _("QueryPerf returned object with unexpected type '%1$s'"),
esxVI_Type_ToString(perfEntityMetric->value->_type));
goto cleanup;
}
if (nvcpus > maxVcpus) {
virReportError(VIR_ERR_INVALID_ARG,
- _("Requested number of virtual CPUs is greater than max "
- "allowable number of virtual CPUs for the domain: %d > %d"),
+ _("Requested number of virtual CPUs is greater than max allowable number of virtual CPUs for the domain: %1$d > %2$d"),
nvcpus, maxVcpus);
return -1;
}
if (taskInfoState != esxVI_TaskInfoState_Success) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not set number of virtual CPUs to %d: %s"), nvcpus,
+ _("Could not set number of virtual CPUs to %1$d: %2$s"), nvcpus,
taskInfoErrorMessage);
goto cleanup;
}
if (STRNEQ(nativeFormat, VMX_CONFIG_FORMAT_ARGV)) {
virReportError(VIR_ERR_INVALID_ARG,
- _("Unsupported config format '%s'"), nativeFormat);
+ _("Unsupported config format '%1$s'"), nativeFormat);
return NULL;
}
if (STRNEQ(nativeFormat, VMX_CONFIG_FORMAT_ARGV)) {
virReportError(VIR_ERR_INVALID_ARG,
- _("Unsupported config format '%s'"), nativeFormat);
+ _("Unsupported config format '%1$s'"), nativeFormat);
return NULL;
}
}
if (taskInfoState != esxVI_TaskInfoState_Success) {
- virReportError(VIR_ERR_INTERNAL_ERROR, _("Could not start domain: %s"),
+ virReportError(VIR_ERR_INTERNAL_ERROR, _("Could not start domain: %1$s"),
taskInfoErrorMessage);
goto cleanup;
}
if (!virStringHasCaseSuffix(src, ".vmdk")) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Expecting source '%s' of first file-based harddisk to "
- "be a VMDK image"), src);
+ _("Expecting source '%1$s' of first file-based harddisk to be a VMDK image"),
+ src);
goto cleanup;
}
}
if (taskInfoState != esxVI_TaskInfoState_Success) {
- virReportError(VIR_ERR_INTERNAL_ERROR, _("Could not define domain: %s"),
+ virReportError(VIR_ERR_INTERNAL_ERROR, _("Could not define domain: %1$s"),
taskInfoErrorMessage);
goto cleanup;
}
if (params[i].value.l < 0) {
virReportError(VIR_ERR_INVALID_ARG,
- _("Could not set reservation to %lld MHz, expecting "
- "positive value"), params[i].value.l);
+ _("Could not set reservation to %1$lld MHz, expecting positive value"),
+ params[i].value.l);
goto cleanup;
}
if (params[i].value.l < -1) {
virReportError(VIR_ERR_INVALID_ARG,
- _("Could not set limit to %lld MHz, expecting "
- "positive value or -1 (unlimited)"),
+ _("Could not set limit to %1$lld MHz, expecting positive value or -1 (unlimited)"),
params[i].value.l);
goto cleanup;
}
default:
virReportError(VIR_ERR_INVALID_ARG,
- _("Could not set shares to %d, expecting positive "
- "value or -1 (low), -2 (normal) or -3 (high)"),
+ _("Could not set shares to %1$d, expecting positive value or -1 (low), -2 (normal) or -3 (high)"),
params[i].value.i);
goto cleanup;
}
if (taskInfoState != esxVI_TaskInfoState_Success) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not change scheduler parameters: %s"),
+ _("Could not change scheduler parameters: %1$s"),
taskInfoErrorMessage);
goto cleanup;
}
*/
if (eventList->fullFormattedMessage) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not migrate domain, validation reported a "
- "problem: %s"), eventList->fullFormattedMessage);
+ _("Could not migrate domain, validation reported a problem: %1$s"),
+ eventList->fullFormattedMessage);
} else {
virReportError(VIR_ERR_INTERNAL_ERROR, "%s",
_("Could not migrate domain, validation reported a "
if (taskInfoState != esxVI_TaskInfoState_Success) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not migrate domain, migration task finished with "
- "an error: %s"),
+ _("Could not migrate domain, migration task finished with an error: %1$s"),
taskInfoErrorMessage);
goto cleanup;
}
if (snapshotTree) {
virReportError(VIR_ERR_OPERATION_INVALID,
- _("Snapshot '%s' already exists"), def->parent.name);
+ _("Snapshot '%1$s' already exists"), def->parent.name);
goto cleanup;
}
}
if (taskInfoState != esxVI_TaskInfoState_Success) {
- virReportError(VIR_ERR_INTERNAL_ERROR, _("Could not create snapshot: %s"),
+ virReportError(VIR_ERR_INTERNAL_ERROR, _("Could not create snapshot: %1$s"),
taskInfoErrorMessage);
goto cleanup;
}
if (!snapshotTreeParent) {
virReportError(VIR_ERR_NO_DOMAIN_SNAPSHOT,
- _("snapshot '%s' does not have a parent"),
+ _("snapshot '%1$s' does not have a parent"),
snapshotTree->name);
goto cleanup;
}
if (taskInfoState != esxVI_TaskInfoState_Success) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not revert to snapshot '%s': %s"), snapshot->name,
+ _("Could not revert to snapshot '%1$s': %2$s"), snapshot->name,
taskInfoErrorMessage);
goto cleanup;
}
if (taskInfoState != esxVI_TaskInfoState_Success) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not delete snapshot '%s': %s"), snapshot->name,
+ _("Could not delete snapshot '%1$s': %2$s"), snapshot->name,
taskInfoErrorMessage);
goto cleanup;
}
if (taskInfoState != esxVI_TaskInfoState_Success) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not change memory parameters: %s"),
+ _("Could not change memory parameters: %1$s"),
taskInfoErrorMessage);
goto cleanup;
}
if (!managedObjectReference) {
virReportError(VIR_ERR_NO_DOMAIN,
- _("Could not find domain with UUID '%s'"),
+ _("Could not find domain with UUID '%1$s'"),
uuid_string);
goto cleanup;
}
virCheckFlags(0, -1);
if (source != VIR_DOMAIN_INTERFACE_ADDRESSES_SRC_AGENT) {
virReportError(VIR_ERR_ARGUMENT_UNSUPPORTED,
- _("Unknown IP address data source %d"),
+ _("Unknown IP address data source %1$d"),
source);
return -1;
}
if (!guestNicInfoList) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Missing property '%s' in answer"),
+ _("Missing property '%1$s' in answer"),
"guest.net");
goto cleanup;
}
virUUIDFormat(uuid, uuid_string);
virReportError(VIR_ERR_NO_NETWORK,
- _("Could not find HostVirtualSwitch with UUID '%s'"),
+ _("Could not find HostVirtualSwitch with UUID '%1$s'"),
uuid_string);
goto cleanup;
case VIR_NETWORK_FORWARD_PASSTHROUGH:
case VIR_NETWORK_FORWARD_HOSTDEV:
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
- _("Unsupported forward mode '%s'"),
+ _("Unsupported forward mode '%1$s'"),
virNetworkForwardTypeToString(def->forward.type));
goto cleanup;
hostPortGroup = hostPortGroup->_next) {
if (STREQ(def->portGroups[i].name, hostPortGroup->spec->name)) {
virReportError(VIR_ERR_NETWORK_EXIST,
- _("HostPortGroup with name '%s' exists already"),
+ _("HostPortGroup with name '%1$s' exists already"),
def->portGroups[i].name);
goto cleanup;
}
if (def->forward.ifs[i].type !=
VIR_NETWORK_FORWARD_HOSTDEV_DEVICE_NETDEV) {
virReportError(VIR_ERR_NO_SUPPORT,
- _("unsupported device type in network %s "
- "interface pool"),
+ _("unsupported device type in network %1$s interface pool"),
def->name);
goto cleanup;
}
if (! found) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not find PhysicalNic with name '%s'"),
+ _("Could not find PhysicalNic with name '%1$s'"),
def->forward.ifs[i].device.dev);
goto cleanup;
}
hostPortGroupPort = hostPortGroupPort->_next) {
if (STRNEQ(hostPortGroupPort->type, "virtualMachine")) {
virReportError(VIR_ERR_OPERATION_INVALID,
- _("Cannot undefine HostVirtualSwitch that has a '%s' port"),
+ _("Cannot undefine HostVirtualSwitch that has a '%1$s' port"),
hostPortGroupPort->type);
goto cleanup;
}
if (! found) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not find HostPortGroup for key '%s'"),
+ _("Could not find HostPortGroup for key '%1$s'"),
hostPortGroupKey->value);
goto cleanup;
}
if (! found) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not find HostPortGroup for key '%s'"),
+ _("Could not find HostPortGroup for key '%1$s'"),
hostPortGroupKey->value);
goto cleanup;
}
if (! found) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not find PhysicalNic with key '%s'"),
+ _("Could not find PhysicalNic with key '%1$s'"),
physicalNicKey->value);
goto cleanup;
}
if (! found) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not find HostPortGroup with key '%s'"),
+ _("Could not find HostPortGroup with key '%1$s'"),
hostPortGroupKey->value);
goto cleanup;
}
if (!target) {
/* pool not found */
virReportError(VIR_ERR_NO_STORAGE_POOL,
- _("Could not find storage pool with name '%s'"),
+ _("Could not find storage pool with name '%1$s'"),
pool->name);
goto cleanup;
}
if (!hostScsiDisk) {
virReportError(VIR_ERR_NO_STORAGE_VOL,
- _("Could not find volume with name: %s"),
+ _("Could not find volume with name: %1$s"),
volume->name);
goto cleanup;
}
if (!scsiLun) {
virReportError(VIR_ERR_NO_STORAGE_VOL,
- _("Could find volume with name: %s"), volume->name);
+ _("Could find volume with name: %1$s"), volume->name);
goto cleanup;
}
def.source.format = VIR_STORAGE_POOL_NETFS_CIFS;
} else {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Datastore has unexpected type '%s'"),
+ _("Datastore has unexpected type '%1$s'"),
nasInfo->nas->type);
goto cleanup;
}
if (!tmp || *def->name == '/' || tmp[1] == '\0') {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Volume name '%s' doesn't have expected format "
- "'<directory>/<file>'"), def->name);
+ _("Volume name '%1$s' doesn't have expected format '<directory>/<file>'"),
+ def->name);
goto cleanup;
}
if (!virStringHasCaseSuffix(def->name, ".vmdk")) {
virReportError(VIR_ERR_NO_SUPPORT,
- _("Volume name '%s' has unsupported suffix, "
- "expecting '.vmdk'"), def->name);
+ _("Volume name '%1$s' has unsupported suffix, expecting '.vmdk'"),
+ def->name);
goto cleanup;
}
if (taskInfoState != esxVI_TaskInfoState_Success) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not create volume: %s"),
+ _("Could not create volume: %1$s"),
taskInfoErrorMessage);
goto cleanup;
}
}
} else {
virReportError(VIR_ERR_NO_SUPPORT,
- _("Creation of %s volumes is not supported"),
+ _("Creation of %1$s volumes is not supported"),
virStorageFileFormatTypeToString(def->target.format));
goto cleanup;
}
if (!tmp || *def->name == '/' || tmp[1] == '\0') {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Volume name '%s' doesn't have expected format "
- "'<directory>/<file>'"), def->name);
+ _("Volume name '%1$s' doesn't have expected format '<directory>/<file>'"),
+ def->name);
goto cleanup;
}
if (!virStringHasCaseSuffix(def->name, ".vmdk")) {
virReportError(VIR_ERR_NO_SUPPORT,
- _("Volume name '%s' has unsupported suffix, "
- "expecting '.vmdk'"), def->name);
+ _("Volume name '%1$s' has unsupported suffix, expecting '.vmdk'"),
+ def->name);
goto cleanup;
}
}
if (taskInfoState != esxVI_TaskInfoState_Success) {
- virReportError(VIR_ERR_INTERNAL_ERROR, _("Could not copy volume: %s"),
+ virReportError(VIR_ERR_INTERNAL_ERROR, _("Could not copy volume: %1$s"),
taskInfoErrorMessage);
goto cleanup;
}
}
} else {
virReportError(VIR_ERR_NO_SUPPORT,
- _("Creation of %s volumes is not supported"),
+ _("Creation of %1$s volumes is not supported"),
virStorageFileFormatTypeToString(def->target.format));
goto cleanup;
}
}
if (taskInfoState != esxVI_TaskInfoState_Success) {
- virReportError(VIR_ERR_INTERNAL_ERROR, _("Could not delete volume: %s"),
+ virReportError(VIR_ERR_INTERNAL_ERROR, _("Could not delete volume: %1$s"),
taskInfoErrorMessage);
goto cleanup;
}
}
if (taskInfoState != esxVI_TaskInfoState_Success) {
- virReportError(VIR_ERR_INTERNAL_ERROR, _("Could not wipe volume: %s"),
+ virReportError(VIR_ERR_INTERNAL_ERROR, _("Could not wipe volume: %1$s"),
taskInfoErrorMessage);
goto cleanup;
}
def.target.format = VIR_STORAGE_FILE_RAW;
} else {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("File '%s' has unknown type"), datastorePath);
+ _("File '%1$s' has unknown type"), datastorePath);
goto cleanup;
}
}
virReportError(VIR_ERR_NO_STORAGE_POOL,
- _("Could not find storage pool with name '%s'"), name);
+ _("Could not find storage pool with name '%1$s'"), name);
return NULL;
}
virUUIDFormat(uuid, uuid_string);
virReportError(VIR_ERR_NO_STORAGE_POOL,
- _("Could not find storage pool with uuid '%s'"),
+ _("Could not find storage pool with uuid '%1$s'"),
uuid_string);
return NULL;
return backends[ISCSI]->storageVolLookupByPath(conn, path);
} else {
virReportError(VIR_ERR_INVALID_ARG,
- _("Unexpected volume path format: %s"), path);
+ _("Unexpected volume path format: %1$s"), path);
return NULL;
}
}
virReportError(VIR_ERR_NO_STORAGE_VOL,
- _("Could not find storage volume with key '%s'"),
+ _("Could not find storage volume with key '%1$s'"),
key);
return NULL;
if (status < 0) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not complete transfer: %s (%d)"),
+ _("Could not complete transfer: %1$s (%2$d)"),
curl_easy_strerror(errorCode), errorCode);
return -1;
}
if (responseCode != 200 && responseCode != 206) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Unexpected HTTP response code %lu"),
+ _("Unexpected HTTP response code %1$lu"),
responseCode);
return -1;
}
if (STRNEQ((*parsedUri)->transport, "http") &&
STRNEQ((*parsedUri)->transport, "https")) {
virReportError(VIR_ERR_INVALID_ARG,
- _("Query parameter 'transport' has unexpected value "
- "'%s' (should be http|https)"),
+ _("Query parameter 'transport' has unexpected value '%1$s' (should be http|https)"),
(*parsedUri)->transport);
goto cleanup;
}
if (virStrToLong_i(queryParam->value, NULL, 10, &noVerify) < 0 ||
(noVerify != 0 && noVerify != 1)) {
virReportError(VIR_ERR_INVALID_ARG,
- _("Query parameter 'no_verify' has unexpected value "
- "'%s' (should be 0 or 1)"), queryParam->value);
+ _("Query parameter 'no_verify' has unexpected value '%1$s' (should be 0 or 1)"),
+ queryParam->value);
goto cleanup;
}
if (virStrToLong_i(queryParam->value, NULL, 10, &autoAnswer) < 0 ||
(autoAnswer != 0 && autoAnswer != 1)) {
virReportError(VIR_ERR_INVALID_ARG,
- _("Query parameter 'auto_answer' has unexpected "
- "value '%s' (should be 0 or 1)"), queryParam->value);
+ _("Query parameter 'auto_answer' has unexpected value '%1$s' (should be 0 or 1)"),
+ queryParam->value);
goto cleanup;
}
*tmp = '\0';
virReportError(VIR_ERR_INVALID_ARG,
- _("Query parameter 'proxy' contains unexpected "
- "type '%s' (should be (http|socks(|4|4a|5))"),
+ _("Query parameter 'proxy' contains unexpected type '%1$s' (should be (http|socks(|4|4a|5))"),
queryParam->value);
goto cleanup;
} else {
(*parsedUri)->proxy_port < 1 ||
(*parsedUri)->proxy_port > 65535) {
virReportError(VIR_ERR_INVALID_ARG,
- _("Query parameter 'proxy' has unexpected "
- "port value '%s' (should be [1..65535])"),
+ _("Query parameter 'proxy' has unexpected port value '%1$s' (should be [1..65535])"),
tmp);
goto cleanup;
}
if (!(tmp = STRSKIP(copyOfDatastorePath, "[")) || *tmp == ']' ||
!(preliminaryDatastoreName = strtok_r(tmp, "]", &saveptr))) {
virReportError(VIR_ERR_INVALID_ARG,
- _("Datastore path '%s' doesn't have expected format "
- "'[<datastore>] <path>'"), datastorePath);
+ _("Datastore path '%1$s' doesn't have expected format '[<datastore>] <path>'"),
+ datastorePath);
goto cleanup;
}
if (errcode != 0) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("IP address lookup for host '%s' failed: %s"), hostname,
+ _("IP address lookup for host '%1$s' failed: %2$s"), hostname,
gai_strerror(errcode));
return -1;
}
if (!result) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("No IP address for host '%s' found: %s"), hostname,
+ _("No IP address for host '%1$s' found: %2$s"), hostname,
gai_strerror(errcode));
return -1;
}
if (errcode != 0) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Formatting IP address for host '%s' failed: %s"), hostname,
+ _("Formatting IP address for host '%1$s' failed: %2$s"), hostname,
gai_strerror(errcode));
return -1;
}
if (virUUIDParse(input, uuid) < 0) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not parse UUID from string '%s'"),
+ _("Could not parse UUID from string '%1$s'"),
input);
return -1;
}
if (errorCode != CURLE_OK) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("curl_easy_perform() returned an error: %s (%d) : %s"),
+ _("curl_easy_perform() returned an error: %1$s (%2$d) : %3$s"),
curl_easy_strerror(errorCode), errorCode, curl->error);
return -1;
}
if (errorCode != CURLE_OK) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("curl_easy_getinfo(CURLINFO_RESPONSE_CODE) returned an "
- "error: %s (%d) : %s"), curl_easy_strerror(errorCode),
+ _("curl_easy_getinfo(CURLINFO_RESPONSE_CODE) returned an error: %1$s (%2$d) : %3$s"),
+ curl_easy_strerror(errorCode),
errorCode, curl->error);
return -1;
}
if (errorCode != CURLE_OK) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("curl_easy_getinfo(CURLINFO_REDIRECT_URL) returned "
- "an error: %s (%d) : %s"),
+ _("curl_easy_getinfo(CURLINFO_REDIRECT_URL) returned an error: %1$s (%2$d) : %3$s"),
curl_easy_strerror(errorCode),
errorCode, curl->error);
} else {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("The server redirects from '%s' to '%s'"), url,
+ _("The server redirects from '%1$s' to '%2$s'"),
+ url,
redirectUrl);
}
return -1;
} else if (responseCode != 200 && responseCode != 206) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("HTTP response code %d for download from '%s'"),
+ _("HTTP response code %1$d for download from '%2$s'"),
responseCode, url);
return -1;
}
return -1;
} else if (responseCode != 200 && responseCode != 201) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("HTTP response code %d for upload to '%s'"),
+ _("HTTP response code %1$d for upload to '%2$s'"),
responseCode, url);
return -1;
}
break;
default:
- VIR_ERROR(_("Trying to lock unknown SharedCURL lock %d"), (int)data);
+ VIR_ERROR(_("Trying to lock unknown SharedCURL lock %1$d"), (int)data);
return;
}
break;
default:
- VIR_ERROR(_("Trying to unlock unknown SharedCURL lock %d"), (int)data);
+ VIR_ERROR(_("Trying to unlock unknown SharedCURL lock %1$d"), (int)data);
return;
}
if (errorCode != CURLM_OK) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not wait for transfer: %s (%d)"),
+ _("Could not wait for transfer: %1$s (%2$d)"),
curl_multi_strerror(errorCode), errorCode);
return -1;
}
if (errorCode != CURLM_OK) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not transfer data: %s (%d)"),
+ _("Could not transfer data: %1$s (%2$d)"),
curl_multi_strerror(errorCode), errorCode);
return -1;
}
if (STRNEQ(ctx->service->about->apiType, "HostAgent") &&
STRNEQ(ctx->service->about->apiType, "VirtualCenter")) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Expecting VI API type 'HostAgent' or 'VirtualCenter' "
- "but found '%s'"), ctx->service->about->apiType);
+ _("Expecting VI API type 'HostAgent' or 'VirtualCenter' but found '%1$s'"),
+ ctx->service->about->apiType);
return -1;
}
if (virStringParseVersion(&ctx->apiVersion,
ctx->service->about->apiVersion, true) < 0) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not parse VI API version '%s'"),
+ _("Could not parse VI API version '%1$s'"),
ctx->service->about->apiVersion);
return -1;
}
if (ctx->apiVersion < 1000000 * 2 + 1000 * 5 /* 2.5 */) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Minimum supported %s version is %s but found version '%s'"),
+ _("Minimum supported %1$s version is %2$s but found version '%3$s'"),
"VI API", "2.5", ctx->service->about->apiVersion);
return -1;
}
if (virStringParseVersion(&ctx->productVersion,
ctx->service->about->version, true) < 0) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not parse product version '%s'"),
+ _("Could not parse product version '%1$s'"),
ctx->service->about->version);
return -1;
}
if (STREQ(ctx->service->about->productLineId, "gsx")) {
if (ctx->productVersion < 1000000 * 2 + 1000 * 0 /* 2.0 */) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Minimum supported %s version is %s but found version '%s'"),
+ _("Minimum supported %1$s version is %2$s but found version '%3$s'"),
esxVI_ProductLineToDisplayName(esxVI_ProductLine_GSX),
"2.0", ctx->service->about->version);
return -1;
STREQ(ctx->service->about->productLineId, "embeddedEsx")) {
if (ctx->productVersion < 1000000 * 3 + 1000 * 5 /* 3.5 */) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Minimum supported %s version is %s but found version '%s'"),
+ _("Minimum supported %1$s version is %2$s but found version '%3$s'"),
esxVI_ProductLineToDisplayName(esxVI_ProductLine_ESX),
"3.5", ctx->service->about->version);
return -1;
} else if (STREQ(ctx->service->about->productLineId, "vpx")) {
if (ctx->productVersion < 1000000 * 2 + 1000 * 5 /* 2.5 */) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Minimum supported %s version is %s but found version '%s'"),
+ _("Minimum supported %1$s version is %2$s but found version '%3$s'"),
esxVI_ProductLineToDisplayName(esxVI_ProductLine_VPX),
"2.5", ctx->service->about->version);
return -1;
ctx->productLine = esxVI_ProductLine_VPX;
} else {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Expecting product 'gsx' or 'esx' or 'embeddedEsx' "
- "or 'vpx' but found '%s'"),
+ _("Expecting product 'gsx' or 'esx' or 'embeddedEsx' or 'vpx' but found '%1$s'"),
ctx->service->about->productLineId);
return -1;
}
if (!item) {
virReportError(VIR_ERR_INVALID_ARG,
- _("Path '%s' does not specify a datacenter"), path);
+ _("Path '%1$s' does not specify a datacenter"), path);
goto cleanup;
}
if (!ctx->datacenter) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not find datacenter specified in '%s'"), path);
+ _("Could not find datacenter specified in '%1$s'"), path);
goto cleanup;
}
/* Lookup (Cluster)ComputeResource */
if (!item) {
virReportError(VIR_ERR_INVALID_ARG,
- _("Path '%s' does not specify a compute resource"), path);
+ _("Path '%1$s' does not specify a compute resource"), path);
goto cleanup;
}
if (!ctx->computeResource) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not find compute resource specified in '%s'"),
+ _("Could not find compute resource specified in '%1$s'"),
path);
goto cleanup;
}
"ClusterComputeResource")) {
if (!item) {
virReportError(VIR_ERR_INVALID_ARG,
- _("Path '%s' does not specify a host system"), path);
+ _("Path '%1$s' does not specify a host system"), path);
goto cleanup;
}
if (item) {
virReportError(VIR_ERR_INVALID_ARG,
- _("Path '%s' ends with an excess item"), path);
+ _("Path '%1$s' ends with an excess item"), path);
goto cleanup;
}
if (!ctx->hostSystem) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not find host system specified in '%s'"), path);
+ _("Could not find host system specified in '%1$s'"), path);
goto cleanup;
}
if (!(*response)->node) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("HTTP response code %d for call to '%s'. "
- "Fault is unknown, XPath evaluation failed"),
+ _("HTTP response code %1$d for call to '%2$s'. Fault is unknown, XPath evaluation failed"),
(*response)->responseCode, methodName);
goto cleanup;
}
if (esxVI_Fault_Deserialize((*response)->node, &fault) < 0) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("HTTP response code %d for call to '%s'. "
- "Fault is unknown, deserialization failed"),
+ _("HTTP response code %1$d for call to '%2$s'. Fault is unknown, deserialization failed"),
(*response)->responseCode, methodName);
goto cleanup;
}
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("HTTP response code %d for call to '%s'. "
- "Fault: %s - %s"), (*response)->responseCode,
+ _("HTTP response code %1$d for call to '%2$s'. Fault: %3$s - %4$s"),
+ (*response)->responseCode,
methodName, fault->faultcode, fault->faultstring);
/* FIXME: Dump raw response until detail part gets deserialized */
if (!responseNode) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("XPath evaluation of response for call to '%s' "
- "failed"), methodName);
+ _("XPath evaluation of response for call to '%1$s' failed"),
+ methodName);
goto cleanup;
}
case esxVI_Occurrence_RequiredItem:
if (!(*response)->node) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Call to '%s' returned an empty result, "
- "expecting a non-empty result"), methodName);
+ _("Call to '%1$s' returned an empty result, expecting a non-empty result"),
+ methodName);
goto cleanup;
} else if ((*response)->node->next) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Call to '%s' returned a list, expecting "
- "exactly one item"), methodName);
+ _("Call to '%1$s' returned a list, expecting exactly one item"),
+ methodName);
goto cleanup;
}
case esxVI_Occurrence_RequiredList:
if (!(*response)->node) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Call to '%s' returned an empty result, "
- "expecting a non-empty result"), methodName);
+ _("Call to '%1$s' returned an empty result, expecting a non-empty result"),
+ methodName);
goto cleanup;
}
if ((*response)->node &&
(*response)->node->next) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Call to '%s' returned a list, expecting "
- "exactly one item"), methodName);
+ _("Call to '%1$s' returned a list, expecting exactly one item"),
+ methodName);
goto cleanup;
}
case esxVI_Occurrence_None:
if ((*response)->node) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Call to '%s' returned something, expecting "
- "an empty result"), methodName);
+ _("Call to '%1$s' returned something, expecting an empty result"),
+ methodName);
goto cleanup;
}
}
} else {
virReportError(VIR_ERR_HTTP_ERROR,
- _("HTTP response code %d for call to '%s'"),
+ _("HTTP response code %1$d for call to '%2$s'"),
(*response)->responseCode, methodName);
goto cleanup;
}
if (anyType->type != enumeration->type) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Expecting type '%s' but found '%s'"),
+ _("Expecting type '%1$s' but found '%2$s'"),
esxVI_Type_ToString(enumeration->type),
esxVI_AnyType_TypeToString(anyType));
return -1;
}
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Unknown value '%s' for %s"), anyType->value,
+ _("Unknown value '%1$s' for %2$s"), anyType->value,
esxVI_Type_ToString(enumeration->type));
return -1;
}
if (result < 0) {
- virReportError(VIR_ERR_INTERNAL_ERROR, _("Unknown value '%s' for %s"),
+ virReportError(VIR_ERR_INTERNAL_ERROR, _("Unknown value '%1$s' for %2$s"),
name, esxVI_Type_ToString(enumeration->type));
}
if (! STRPREFIX(anyType->other, "ArrayOf")) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Expecting type to begin with 'ArrayOf' but found '%s'"),
+ _("Expecting type to begin with 'ArrayOf' but found '%1$s'"),
anyType->other);
return -1;
}
childNode = childNode->next) {
if (childNode->type != XML_ELEMENT_NODE) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Wrong XML element type %d"), childNode->type);
+ _("Wrong XML element type %1$d"), childNode->type);
goto cleanup;
}
for (; node; node = node->next) {
if (node->type != XML_ELEMENT_NODE) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Wrong XML element type %d"), node->type);
+ _("Wrong XML element type %1$d"), node->type);
goto failure;
}
objectSpec->selectSet = ctx->selectSet_folderToChildEntity;
} else {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Invalid lookup of '%s' from '%s'"),
+ _("Invalid lookup of '%1$s' from '%2$s'"),
type, root->type);
goto cleanup;
}
objectSpec->selectSet = ctx->selectSet_computeResourceToParentToParent;
} else {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Invalid lookup of '%s' from '%s'"),
+ _("Invalid lookup of '%1$s' from '%2$s'"),
type, root->type);
goto cleanup;
}
objectSpec->selectSet = ctx->selectSet_hostSystemToDatastore;
} else {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Invalid lookup of '%s' from '%s'"),
+ _("Invalid lookup of '%1$s' from '%2$s'"),
type, root->type);
goto cleanup;
}
objectSpec->selectSet = ctx->selectSet_datacenterToNetwork;
} else {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Invalid lookup of '%s' from '%s'"),
+ _("Invalid lookup of '%1$s' from '%2$s'"),
type, root->type);
goto cleanup;
}
} else {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Invalid lookup from '%s'"), root->type);
+ _("Invalid lookup from '%1$s'"), root->type);
goto cleanup;
}
}
case esxVI_Occurrence_RequiredItem:
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not lookup '%s' from '%s'"),
+ _("Could not lookup '%1$s' from '%2$s'"),
type, root->type);
break;
case esxVI_Occurrence_RequiredList:
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not lookup '%s' list from '%s'"),
+ _("Could not lookup '%1$s' list from '%2$s'"),
type, root->type);
break;
}
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Missing '%s' property while looking for "
- "ManagedEntityStatus"), propertyName);
+ _("Missing '%1$s' property while looking for ManagedEntityStatus"),
+ propertyName);
return -1;
}
if (*value == esxVI_Boolean_Undefined &&
occurrence == esxVI_Occurrence_RequiredItem) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Missing '%s' property"), propertyName);
+ _("Missing '%1$s' property"), propertyName);
return -1;
}
if (!(*value) && occurrence == esxVI_Occurrence_RequiredItem) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Missing '%s' property"), propertyName);
+ _("Missing '%1$s' property"), propertyName);
return -1;
}
if (!(*value) && occurrence == esxVI_Occurrence_RequiredItem) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Missing '%s' property"), propertyName);
+ _("Missing '%1$s' property"), propertyName);
return -1;
}
if (!(*value) && occurrence == esxVI_Occurrence_RequiredItem) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Missing '%s' property"), propertyName);
+ _("Missing '%1$s' property"), propertyName);
return -1;
}
if (!(*value) && occurrence == esxVI_Occurrence_RequiredItem) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Missing '%s' property"), propertyName);
+ _("Missing '%1$s' property"), propertyName);
return -1;
}
if (esxUtil_ParseVirtualMachineIDString
(virtualMachine->obj->value, id) < 0 || *id <= 0) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not parse positive integer from '%s'"),
+ _("Could not parse positive integer from '%1$s'"),
virtualMachine->obj->value);
goto failure;
}
if (virUUIDParse(uuid_string, uuid) < 0) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not parse UUID from string '%s'"),
+ _("Could not parse UUID from string '%1$s'"),
uuid_string);
goto failure;
}
return 0;
} else {
virReportError(VIR_ERR_NO_DOMAIN_SNAPSHOT,
- _("Could not find snapshot with name '%s'"), name);
+ _("Could not find snapshot with name '%1$s'"), name);
return -1;
}
}
virReportError(VIR_ERR_NO_DOMAIN_SNAPSHOT,
- _("Could not find domain snapshot with internal name '%s'"),
+ _("Could not find domain snapshot with internal name '%1$s'"),
snapshot->value);
return -1;
goto cleanup;
} else {
virReportError(VIR_ERR_NO_DOMAIN,
- _("Could not find domain with UUID '%s'"),
+ _("Could not find domain with UUID '%1$s'"),
uuid_string);
goto cleanup;
}
if (!(*virtualMachine) && occurrence != esxVI_Occurrence_OptionalItem) {
virReportError(VIR_ERR_NO_DOMAIN,
- _("Could not find domain with name '%s'"), name);
+ _("Could not find domain with name '%1$s'"), name);
goto cleanup;
}
if (!(*datastore) && occurrence != esxVI_Occurrence_OptionalItem) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not find datastore with name '%s'"), name);
+ _("Could not find datastore with name '%1$s'"), name);
goto cleanup;
}
if (!(*datastore) && occurrence != esxVI_Occurrence_OptionalItem) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not find datastore containing absolute path '%s'"),
+ _("Could not find datastore containing absolute path '%1$s'"),
absolutePath);
goto cleanup;
}
if (directoryAndFileName[length] != '/' ||
directoryAndFileName[length + 1] == '\0') {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Datastore path '%s' doesn't reference a file"),
+ _("Datastore path '%1$s' doesn't reference a file"),
datastorePath);
goto cleanup;
}
if (taskInfoState != esxVI_TaskInfoState_Success) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not search in datastore '%s': %s"),
+ _("Could not search in datastore '%1$s': %2$s"),
datastoreName, taskInfoErrorMessage);
goto cleanup;
}
goto cleanup;
} else {
virReportError(VIR_ERR_NO_STORAGE_VOL,
- _("No storage volume with key or path '%s'"),
+ _("No storage volume with key or path '%1$s'"),
datastorePath);
goto cleanup;
}
if (taskInfoState != esxVI_TaskInfoState_Success) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not search in datastore '%s': %s"),
+ _("Could not search in datastore '%1$s': %2$s"),
datastoreName, taskInfoErrorMessage);
goto cleanup;
}
if (!(*physicalNic) && occurrence != esxVI_Occurrence_OptionalItem) {
virReportError(VIR_ERR_NO_INTERFACE,
- _("Could not find physical NIC with name '%s'"), name);
+ _("Could not find physical NIC with name '%1$s'"), name);
goto cleanup;
}
if (!(*physicalNic) && occurrence != esxVI_Occurrence_OptionalItem) {
virReportError(VIR_ERR_NO_INTERFACE,
- _("Could not find physical NIC with MAC address '%s'"), mac);
+ _("Could not find physical NIC with MAC address '%1$s'"), mac);
goto cleanup;
}
if (!(*hostVirtualSwitch) &&
occurrence != esxVI_Occurrence_OptionalItem) {
virReportError(VIR_ERR_NO_NETWORK,
- _("Could not find HostVirtualSwitch with name '%s'"),
+ _("Could not find HostVirtualSwitch with name '%1$s'"),
name);
goto cleanup;
}
if (autoAnswer) {
if (!possibleAnswers) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Pending question blocks virtual machine execution, "
- "question is '%s', no possible answers"),
+ _("Pending question blocks virtual machine execution, question is '%1$s', no possible answers"),
questionInfo->text);
*blocked = true;
return -1;
} else if (!answerChoice) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Pending question blocks virtual machine execution, "
- "question is '%s', possible answers are %s, but no "
- "default answer is specified"), questionInfo->text,
+ _("Pending question blocks virtual machine execution, question is '%1$s', possible answers are %2$s, but no default answer is specified"),
+ questionInfo->text,
possibleAnswers);
*blocked = true;
} else {
if (possibleAnswers) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Pending question blocks virtual machine execution, "
- "question is '%s', possible answers are %s"),
+ _("Pending question blocks virtual machine execution, question is '%1$s', possible answers are %2$s"),
questionInfo->text, possibleAnswers);
} else {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Pending question blocks virtual machine execution, "
- "question is '%s', no possible answers"),
+ _("Pending question blocks virtual machine execution, question is '%1$s', no possible answers"),
questionInfo->text);
}
for (r = 0; r < 4; ++r) {
if (strlen(input[r]) != expectedLength) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("HostCpuIdInfo register '%s' has an unexpected length"),
+ _("HostCpuIdInfo register '%1$s' has an unexpected length"),
name[r]);
return -1;
}
if (i + 4 < expectedLength && input[r][i + 4] != ':') {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("HostCpuIdInfo register '%s' has an unexpected format"),
+ _("HostCpuIdInfo register '%1$s' has an unexpected format"),
name[r]);
return -1;
}
if (!candidate) {
if (occurrence == esxVI_Occurrence_RequiredItem) {
virReportError(VIR_ERR_NO_STORAGE_POOL,
- _("Could not find storage pool with name: %s"), name);
+ _("Could not find storage pool with name: %1$s"), name);
}
goto cleanup;
if (!esxVI_String_ListContainsValue(propertyNameList, "name")) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Missing 'name' property in %s lookup"), type);
+ _("Missing 'name' property in %1$s lookup"), type);
goto cleanup;
}
if (occurrence != esxVI_Occurrence_OptionalItem) {
if (name) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not find %s with name '%s'"), type, name);
+ _("Could not find %1$s with name '%2$s'"), type, name);
} else {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Could not find %s"), type);
+ _("Could not find %1$s"), type);
}
goto cleanup;
if (item->_type <= esxVI_Type_Undefined || \
item->_type >= esxVI_Type_Other) { \
virReportError(VIR_ERR_INTERNAL_ERROR, \
- _("%s object has invalid dynamic type"), typeName);\
+ _("%1$s object has invalid dynamic type"), typeName);\
return -1; \
} \
\
{ \
if (anyType->type != esxVI_Type_##_type) { \
virReportError(VIR_ERR_INTERNAL_ERROR, \
- _("Call to %s for unexpected type '%s', " \
- "expected '%s'"), \
+ _("Call to %1$s for unexpected type '%2$s', expected '%3$s'"), \
__FUNCTION__, anyType->other, \
esxVI_Type_ToString(esxVI_Type_##_type)); \
return -1; \
{ \
if (anyType->type != esxVI_Type_##_type) { \
virReportError(VIR_ERR_INTERNAL_ERROR, \
- _("Call to %s for unexpected type '%s', " \
- "expected '%s'"), \
+ _("Call to %1$s for unexpected type '%2$s', expected '%3$s'"), \
__FUNCTION__, anyType->other, \
esxVI_Type_ToString(esxVI_Type_##_type)); \
return -1; \
childNode = childNode->next) { \
if (childNode->type != XML_ELEMENT_NODE) { \
virReportError(VIR_ERR_INTERNAL_ERROR, \
- _("Wrong XML element type %d"), \
+ _("Wrong XML element type %1$d"), \
childNode->type); \
goto failure; \
} \
\
if (!string) { \
virReportError(VIR_ERR_INTERNAL_ERROR, \
- _("XML node doesn't contain text, expecting an %s "\
- "value"), _xsdType); \
+ _("XML node doesn't contain text, expecting an %1$s value"), \
+ _xsdType); \
goto cleanup; \
} \
\
if (virStrToLong_ll(string, NULL, 10, &value) < 0) { \
virReportError(VIR_ERR_INTERNAL_ERROR, \
- _("Unknown value '%s' for %s"), string, _xsdType); \
+ _("Unknown value '%1$s' for %2$s"), string, _xsdType); \
goto cleanup; \
} \
\
if (((_min) != INT64_MIN && value < (_min)) \
|| ((_max) != INT64_MAX && value > (_max))) { \
virReportError(VIR_ERR_INTERNAL_ERROR, \
- _("Value '%s' is not representable as %s"), \
+ _("Value '%1$s' is not representable as %2$s"), \
string, _xsdType); \
goto cleanup; \
} \
#define ESX_VI__TEMPLATE__PROPERTY__REQUIRE(_name) \
if (item->_name == 0) { \
virReportError(VIR_ERR_INTERNAL_ERROR, \
- _("%s object is missing the required '%s' property"), \
+ _("%1$s object is missing the required '%2$s' property"), \
typeName, #_name); \
return -1; \
}
\
default: \
virReportError(VIR_ERR_INTERNAL_ERROR, \
- _("Call to %s for unexpected type '%s'"), \
+ _("Call to %1$s for unexpected type '%2$s'"), \
__FUNCTION__, _actual_type_name); \
return _error_return; \
}
\
default: \
virReportError(VIR_ERR_INTERNAL_ERROR, \
- _("Call to %s for unexpected type '%s'"), \
+ _("Call to %1$s for unexpected type '%2$s'"), \
__FUNCTION__, esxVI_Type_ToString(type)); \
return -1; \
}, \
if (*actualType == esxVI_Type_Undefined || *actualType == esxVI_Type_Other) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Unknown value '%s' for %s 'type' property"),
+ _("Unknown value '%1$s' for %2$s 'type' property"),
type, esxVI_Type_ToString(baseType));
return -1;
}
if (item->_name == 0 && \
esxVI_String_ListContainsValue(selectedPropertyNameList, #_name)) { \
virReportError(VIR_ERR_INTERNAL_ERROR, \
- _("%s object is missing the required '%s' property"), \
+ _("%1$s object is missing the required '%2$s' property"), \
typeName, #_name); \
return -1; \
}
if (item->_type <= esxVI_Type_Undefined || \
item->_type >= esxVI_Type_Other) { \
virReportError(VIR_ERR_INTERNAL_ERROR, \
- _("%s object has invalid dynamic type"), typeName);\
+ _("%1$s object has invalid dynamic type"), typeName);\
return -1; \
} \
\
{
if (anyType->type != type) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Expecting type '%s' but found '%s'"),
+ _("Expecting type '%1$s' but found '%2$s'"),
esxVI_Type_ToString(type),
esxVI_AnyType_TypeToString(anyType));
return -1;
if ((*anyType)->type == esxVI_Type_Undefined) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Unknown value '%s' for AnyType 'type' property"),
+ _("Unknown value '%1$s' for AnyType 'type' property"),
(*anyType)->other);
goto failure;
}
do { \
if (virStrToLong_ll((*anyType)->value, NULL, 10, &number) < 0) { \
virReportError(VIR_ERR_INTERNAL_ERROR, \
- _("Unknown value '%s' for %s"), \
+ _("Unknown value '%1$s' for %2$s"), \
(*anyType)->value, _xsdType); \
goto failure; \
} \
if (((_min) != INT64_MIN && number < (_min)) \
|| ((_max) != INT64_MAX && number > (_max))) { \
virReportError(VIR_ERR_INTERNAL_ERROR, \
- _("Value '%s' is out of %s range"), \
+ _("Value '%1$s' is out of %2$s range"), \
(*anyType)->value, _xsdType); \
goto failure; \
} \
(*anyType)->boolean = esxVI_Boolean_False;
} else {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Unknown value '%s' for xsd:boolean"),
+ _("Unknown value '%1$s' for xsd:boolean"),
(*anyType)->value);
goto failure;
}
/* second */
virStrToLong_i(tmp+1, &tmp, 10, &sec) < 0) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("xsd:dateTime value '%s' has unexpected format"),
+ _("xsd:dateTime value '%1$s' has unexpected format"),
dateTime->value);
return -1;
}
if (*tmp == '.' &&
virStrToLong_i(tmp + 1, &tmp, 10, &milliseconds) < 0) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("xsd:dateTime value '%s' has unexpected format"),
+ _("xsd:dateTime value '%1$s' has unexpected format"),
dateTime->value);
return -1;
}
tz = g_time_zone_new_utc();
} else {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("xsd:dateTime value '%s' has unexpected format"),
+ _("xsd:dateTime value '%1$s' has unexpected format"),
dateTime->value);
return -1;
}
if (!(*ptrptr)->_actualType) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("%s is missing 'type' property"),
+ _("%1$s is missing 'type' property"),
esxVI_Type_ToString((*ptrptr)->_type));
goto failure;
}