mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-07-30 21:47:18 +00:00
xenapi: remove unused variable
CC libvirt_driver_xenapi_la-xenapi_driver.lo xenapi/xenapi_driver.c: In function 'xenapiDomainGetVcpus': xenapi/xenapi_driver.c:1209:21: error: variable 'cpus' set but not used [-Werror=unused-but-set-variable] * src/xenapi/xenapi_driver.c (xenapiDomainGetVcpus): Silence compiler warning.
This commit is contained in:
parent
613f9ea8f7
commit
787b0a2238
@ -1206,7 +1206,7 @@ xenapiDomainGetVcpus (virDomainPtr dom,
|
|||||||
xen_vm_set *vms = NULL;
|
xen_vm_set *vms = NULL;
|
||||||
xen_vm vm = NULL;
|
xen_vm vm = NULL;
|
||||||
xen_string_string_map *vcpu_params = NULL;
|
xen_string_string_map *vcpu_params = NULL;
|
||||||
int nvcpus = 0, cpus = 0, i;
|
int nvcpus = 0, i;
|
||||||
virDomainInfo domInfo;
|
virDomainInfo domInfo;
|
||||||
virNodeInfo nodeInfo;
|
virNodeInfo nodeInfo;
|
||||||
virVcpuInfoPtr ifptr;
|
virVcpuInfoPtr ifptr;
|
||||||
@ -1221,9 +1221,7 @@ xenapiDomainGetVcpus (virDomainPtr dom,
|
|||||||
_("Couldn't fetch Domain Information"));
|
_("Couldn't fetch Domain Information"));
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
if (xenapiNodeGetInfo(dom->conn, &nodeInfo) == 0)
|
if (xenapiNodeGetInfo(dom->conn, &nodeInfo) != 0) {
|
||||||
cpus = nodeInfo.cpus;
|
|
||||||
else {
|
|
||||||
xenapiSessionErrorHandler(dom->conn, VIR_ERR_INTERNAL_ERROR,
|
xenapiSessionErrorHandler(dom->conn, VIR_ERR_INTERNAL_ERROR,
|
||||||
_("Couldn't fetch Node Information"));
|
_("Couldn't fetch Node Information"));
|
||||||
return -1;
|
return -1;
|
||||||
|
Loading…
Reference in New Issue
Block a user