/* From this point on, the connection is for us. */
if (STRNEQ(conn->uri->path, "/system")) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Unexpected Virtuozzo URI path '%s', try vz:///system"),
+ _("Unexpected Virtuozzo URI path '%1$s', try vz:///system"),
conn->uri->path);
return VIR_DRV_OPEN_ERROR;
}
char uuidstr[VIR_UUID_STRING_BUFLEN];
virUUIDFormat(uuid, uuidstr);
virReportError(VIR_ERR_NO_DOMAIN,
- _("no domain with matching uuid '%s'"), uuidstr);
+ _("no domain with matching uuid '%1$s'"), uuidstr);
return NULL;
}
if (dom == NULL) {
virReportError(VIR_ERR_NO_DOMAIN,
- _("no domain with matching name '%s'"), name);
+ _("no domain with matching name '%1$s'"), name);
return NULL;
}
virUUIDFormat(dom->def->uuid, uuidstr);
virReportError(VIR_ERR_NO_DOMAIN,
- _("no domain with matching uuid '%s' (%s)"),
+ _("no domain with matching uuid '%1$s' (%2$s)"),
uuidstr, dom->def->name);
return -1;
goto cleanup;
} else {
virReportError(VIR_ERR_INVALID_ARG,
- _("Unsupported OS type: %s"),
+ _("Unsupported OS type: %1$s"),
virDomainOSTypeToString(def->os.type));
goto cleanup;
}
if (*path) {
if ((idx = virDomainDiskIndexByName(dom->def, path, false)) < 0) {
- virReportError(VIR_ERR_INVALID_ARG, _("invalid path: %s"), path);
+ virReportError(VIR_ERR_INVALID_ARG, _("invalid path: %1$s"), path);
return -1;
}
if (prlsdkGetBlockStats(privdom->stats,
return 1028;
virReportError(VIR_ERR_INVALID_ARG,
- _("unknown type '%s'"), type);
+ _("unknown type '%1$s'"), type);
return -1;
}
snap = virDomainSnapshotFindByName(snapshots, name);
if (!snap)
virReportError(VIR_ERR_NO_DOMAIN_SNAPSHOT,
- _("no domain snapshot with matching name '%s'"), name);
+ _("no domain snapshot with matching name '%1$s'"), name);
return snap;
}
if (!snap->def->parent_name) {
virReportError(VIR_ERR_NO_DOMAIN_SNAPSHOT,
- _("snapshot '%s' does not have a parent"),
+ _("snapshot '%1$s' does not have a parent"),
snap->def->name);
goto cleanup;
}
if (!uri->scheme || !uri->server) {
virReportError(VIR_ERR_INVALID_ARG,
- _("scheme and host are mandatory vz migration URI: %s"),
+ _("scheme and host are mandatory vz migration URI: %1$s"),
uri_str);
goto error;
}
if (uri->user || uri->path || uri->query || uri->fragment) {
virReportError(VIR_ERR_INVALID_ARG,
- _("only scheme, host and port are supported in "
- "vz migration URI: %s"), uri_str);
+ _("only scheme, host and port are supported in vz migration URI: %1$s"),
+ uri_str);
goto error;
}
if (STRNEQ(uri->scheme, "vzmigr")) {
virReportError(VIR_ERR_ARGUMENT_UNSUPPORTED,
- _("unsupported scheme %s in migration URI %s"),
+ _("unsupported scheme %1$s in migration URI %2$s"),
uri->scheme, uri_str);
goto error;
}
} else if ((flags & VIR_CONNECT_GET_ALL_DOMAINS_STATS_ENFORCE_STATS) &&
(stats & ~supported)) {
virReportError(VIR_ERR_ARGUMENT_UNSUPPORTED,
- _("Stats types bits 0x%x are not supported by this daemon"),
+ _("Stats types bits 0x%1$x are not supported by this daemon"),
stats & ~supported);
return -1;
}
if (!(disk = virDomainDiskByName(dom->def, path, false))) {
virReportError(VIR_ERR_INVALID_ARG,
- _("invalid path: %s"), path);
+ _("invalid path: %1$s"), path);
goto cleanup;
}
vz_driver_privileged = privileged;
if (g_mkdir_with_parents(VZ_STATEDIR, S_IRWXU) < 0) {
- virReportSystemError(errno, _("cannot create state directory '%s'"),
+ virReportSystemError(errno, _("cannot create state directory '%1$s'"),
VZ_STATEDIR);
return VIR_DRV_STATE_INIT_ERROR;
}
virReportErrorHelper(VIR_FROM_THIS, VIR_ERR_INTERNAL_ERROR,
filename, funcname, linenr,
- _("%s %s"), msg1, msg2);
+ _("%1$s %2$s"), msg1, msg2);
VIR_FREE(msg1);
VIR_FREE(msg2);
virReportErrorHelper(VIR_FROM_THIS, VIR_ERR_INTERNAL_ERROR,
filename, funcname, linenr,
- _("%s %s"), msg1, msg2);
+ _("%1$s %2$s"), msg1, msg2);
VIR_FREE(msg1);
VIR_FREE(msg2);
}
PGVC_SEARCH_BY_UUID, &sdkdom) < 0) {
virUUIDFormat(uuid, uuidstr);
virReportError(VIR_ERR_NO_DOMAIN,
- _("no domain with matching uuid '%s'"), uuidstr);
+ _("no domain with matching uuid '%1$s'"), uuidstr);
return PRL_INVALID_HANDLE;
}
if (prlsdkSdkDomainLookup(driver, name,
PGVC_SEARCH_BY_NAME, &sdkdom) < 0) {
virReportError(VIR_ERR_NO_DOMAIN,
- _("no domain with matching name '%s'"), name);
+ _("no domain with matching name '%1$s'"), name);
return PRL_INVALID_HANDLE;
}
break;
default:
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Unknown disk bus: %X"), ifType);
+ _("Unknown disk bus: %1$X"), ifType);
return -1;
}
goto cleanup;
if (STRNEQ("libvirt", uri->scheme)) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Unknown uri scheme: '%s'"),
+ _("Unknown uri scheme: '%1$s'"),
uri->scheme);
goto cleanup;
}
if (!(matches = g_strsplit(uri->path, "/", 0)) ||
!matches[0]) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("splitting StorageUrl failed %s"), uri->path);
+ _("splitting StorageUrl failed %1$s"), uri->path);
goto cleanup;
}
if (!matches[1]) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("can't identify pool in uri %s "), uri->path);
+ _("can't identify pool in uri %1$s "), uri->path);
goto cleanup;
}
if (!matches[2]) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("can't identify volume in uri %s"), uri->path);
+ _("can't identify volume in uri %1$s"), uri->path);
goto cleanup;
}
fs->type = VIR_DOMAIN_FS_TYPE_VOLUME;
break;
default:
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Unknown adapter type: %X"), type);
+ _("Unknown adapter type: %1$X"), type);
return -1;
}
}
break;
default:
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Unknown serial type: %X"), emulatedType);
+ _("Unknown serial type: %1$X"), emulatedType);
return -1;
}
break;
default:
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Unknown domain type: %X"), domainType);
+ _("Unknown domain type: %1$X"), domainType);
return -1;
}
break;
default:
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Unknown CPU mode: %X"), cpuMode);
+ _("Unknown CPU mode: %1$X"), cpuMode);
return -1;
}
dev = prlsdkGetDevByDevIndex(sdkdom, sdkType, sdkIndex);
if (dev == PRL_INVALID_HANDLE) {
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
- _("Can't find boot device of type: %d, device index: %d"),
+ _("Can't find boot device of type: %1$d, device index: %2$d"),
sdkType, sdkIndex);
return -1;
}
break;
default:
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
- _("Unsupported disk type %d"), sdkType);
+ _("Unsupported disk type %1$d"), sdkType);
goto cleanup;
}
if (!(disk = virFindDiskBootIndex(def, device, bootIndex))) {
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
- _("Can't find boot device of type: %s, index: %d"),
+ _("Can't find boot device of type: %1$s, index: %2$d"),
virDomainDiskDeviceTypeToString(device), bootIndex);
goto cleanup;
}
if (bootIndex >= def->nnets) {
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
- _("Can't find network boot device for index: %d"),
+ _("Can't find network boot device for index: %1$d"),
bootIndex);
goto cleanup;
}
break;
default:
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
- _("Unexpected device type %d"), sdkType);
+ _("Unexpected device type %1$d"), sdkType);
goto cleanup;
}
break;
default:
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
- _("Unexpected boot device type %i"), sdkType);
+ _("Unexpected boot device type %1$i"), sdkType);
goto cleanup;
}
if (autostart != PAO_VM_START_ON_LOAD &&
autostart != PAO_VM_START_MANUAL) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Unknown autostart mode: %X"), autostart);
+ _("Unknown autostart mode: %1$X"), autostart);
return NULL;
}
if (chr->source->type == VIR_DOMAIN_CHR_TYPE_TCP &&
chr->source->data.tcp.protocol != VIR_DOMAIN_CHR_TCP_PROTOCOL_RAW) {
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
- _("Protocol '%s' is not supported for "
- "tcp character device."),
+ _("Protocol '%1$s' is not supported for tcp character device."),
virDomainChrTcpProtocolTypeToString(chr->source->data.tcp.protocol));
return -1;
}
break;
default:
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
- _("Unsupported address family %d "
- "Only IPv4 or IPv6 default gateway"),
+ _("Unsupported address family %1$d Only IPv4 or IPv6 default gateway"),
VIR_SOCKET_ADDR_FAMILY(gateway));
return -1;
}
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("No net with mac '%s'"), virMacAddrFormat(mac, virMac));
+ _("No net with mac '%1$s'"), virMacAddrFormat(mac, virMac));
cleanup:
PrlHandle_Free(adapter);
}
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("No disk with bus '%s' and target '%s'"),
+ _("No disk with bus '%1$s' and target '%2$s'"),
virDomainDiskBusTypeToString(disk->bus), disk->dst);
return PRL_INVALID_HANDLE;
case VIR_DOMAIN_DEVICE_AUDIO:
case VIR_DOMAIN_DEVICE_CRYPTO:
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
- _("attaching device type '%s' is unsupported"),
+ _("attaching device type '%1$s' is unsupported"),
virDomainDeviceTypeToString(dev->type));
return -1;
}
case VIR_DOMAIN_DEVICE_AUDIO:
case VIR_DOMAIN_DEVICE_CRYPTO:
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
- _("detaching device type '%s' is unsupported"),
+ _("detaching device type '%1$s' is unsupported"),
virDomainDeviceTypeToString(dev->type));
goto cleanup;
}
case VIR_DOMAIN_DEVICE_AUDIO:
case VIR_DOMAIN_DEVICE_CRYPTO:
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
- _("updating device type '%s' is unsupported"),
+ _("updating device type '%1$s' is unsupported"),
virDomainDeviceTypeToString(dev->type));
return -1;
}
case VIR_DOMAIN_BOOT_LAST:
default:
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
- _("Unsupported boot device type: '%s'"),
+ _("Unsupported boot device type: '%1$s'"),
virDomainBootTypeToString(virType));
return -1;
}
break;
default:
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Unknown CPU mode: %s"),
+ _("Unknown CPU mode: %1$s"),
virArchToString(def->os.arch));
goto error;
}
return -1;
if (virStoragePoolIsActive(pool) != 1) {
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
- _("storage pool '%s' containing volume '%s' "
- "is not active"), src->srcpool->pool,
+ _("storage pool '%1$s' containing volume '%2$s' is not active"),
+ src->srcpool->pool,
src->srcpool->volume);
goto cleanup;
}
if (info.type != VIR_STORAGE_VOL_PLOOP) {
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
- _("Unsupported volume format '%s'"),
+ _("Unsupported volume format '%1$s'"),
virStorageVolTypeToString(info.type));
goto cleanup;
}
case VIR_DOMAIN_DISK_BUS_LAST:
default:
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Unknown disk bus: %X"), disk->bus);
+ _("Unknown disk bus: %1$X"), disk->bus);
goto cleanup;
}
}
if (net == PRL_INVALID_HANDLE)
virReportError(VIR_ERR_INVALID_ARG,
- _("invalid path, '%s' is not a known interface"), path);
+ _("invalid path, '%1$s' is not a known interface"), path);
return net;
error:
/* second */
virStrToLong_i(tmp+1, &tmp, 10, &sec) < 0 || *tmp != '\0') {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("unexpected DateTime format: '%s'"), str);
+ _("unexpected DateTime format: '%1$s'"), str);
return -1;
}
def->state = VIR_DOMAIN_SHUTOFF;
} else {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("unexpected snapshot state: %s"), xmlstr);
+ _("unexpected snapshot state: %1$s"), xmlstr);
}
VIR_FREE(xmlstr);
if (!vm) {
virUUIDFormat(domain->uuid, uuidstr);
virReportError(VIR_ERR_NO_DOMAIN,
- _("no domain with matching uuid '%s' (%s)"),
+ _("no domain with matching uuid '%1$s' (%2$s)"),
uuidstr, domain->name);
return NULL;
}
if (drive->controller > 0) {
/* We have only one controller of each type */
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
- _("Invalid drive address of disk %s, vz driver "
- "supports only one controller."), disk->dst);
+ _("Invalid drive address of disk %1$s, vz driver supports only one controller."),
+ disk->dst);
return -1;
}
if (drive->target > 0) {
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
- _("Invalid drive address of disk %s, vz driver "
- "supports only target 0."), disk->dst);
+ _("Invalid drive address of disk %1$s, vz driver supports only target 0."),
+ disk->dst);
return -1;
}
case VIR_DOMAIN_DISK_BUS_IDE:
if (drive->unit > 1) {
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
- _("Invalid drive address of disk %s, vz driver "
- "supports only units 0-1 for IDE bus."),
+ _("Invalid drive address of disk %1$s, vz driver supports only units 0-1 for IDE bus."),
disk->dst);
return -1;
}
case VIR_DOMAIN_DISK_BUS_SATA:
if (drive->bus > 0) {
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
- _("Invalid drive address of disk %s, vz driver "
- "supports only bus 0 for SATA and SCSI bus."),
+ _("Invalid drive address of disk %1$s, vz driver supports only bus 0 for SATA and SCSI bus."),
disk->dst);
return -1;
}
if (virDiskNameToBusDeviceIndex(disk, &busIdx, &devIdx) < 0) {
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("cannot convert disk '%s' to bus/device index"),
+ _("cannot convert disk '%1$s' to bus/device index"),
disk->dst);
return -1;
}
if (busIdx != drive->bus || devIdx != drive->unit) {
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
- _("Invalid drive address of disk %s, vz driver "
- "does not support non default name mappings."),
+ _("Invalid drive address of disk %1$s, vz driver does not support non default name mappings."),
disk->dst);
return -1;
}
if (virDomainDiskGetFormat(disk) != VIR_STORAGE_FILE_NONE &&
virDomainDiskGetFormat(disk) != diskFormat) {
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
- _("Unsupported format of disk %s"),
+ _("Unsupported format of disk %1$s"),
disk->src->path);
return -1;
}
if (vzCaps->diskBuses[i] == VIR_DOMAIN_DISK_BUS_LAST) {
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
- _("Unsupported disk bus type %s"),
+ _("Unsupported disk bus type %1$s"),
virDomainDiskBusTypeToString(disk->bus));
return -1;
}
if (vzCaps->controllerTypes[j] == VIR_DOMAIN_CONTROLLER_TYPE_LAST) {
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
- _("Unsupported controller type %s"),
+ _("Unsupported controller type %1$s"),
virDomainControllerTypeToString(controller->type));
return -1;
}
controller->model != vzCaps->scsiControllerModel) {
virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
- _("Unsupported SCSI controller model %s"),
+ _("Unsupported SCSI controller model %1$s"),
virDomainControllerModelSCSITypeToString(controller->model));
return -1;
}
break;
default:
virReportError(VIR_ERR_INTERNAL_ERROR,
- _("Unknown SCSI controller model %s"),
+ _("Unknown SCSI controller model %1$s"),
virDomainControllerModelSCSITypeToString(
driver->vzCaps.scsiControllerModel));
return -1;