提交 cba7f345 编写于 作者: P Peter Krempa

vz: Remove dead code from vzDomainGetVcpus

'maxcpu' and 'vcpus' are set but not used after that
上级 0b3fcfb1
......@@ -807,7 +807,7 @@ vzDomainGetVcpus(virDomainPtr domain,
{
virDomainObjPtr privdom = NULL;
size_t i;
int v, maxcpu, hostcpus;
int v;
int ret = -1;
if (!(privdom = vzDomObjFromDomainRef(domain)))
......@@ -820,13 +820,6 @@ vzDomainGetVcpus(virDomainPtr domain,
goto cleanup;
}
if ((hostcpus = nodeGetCPUCount()) < 0)
goto cleanup;
maxcpu = maplen * 8;
if (maxcpu > hostcpus)
maxcpu = hostcpus;
if (maxinfo >= 1) {
if (info != NULL) {
memset(info, 0, sizeof(*info) * maxinfo);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册