From: Peter Krempa Date: Thu, 14 Aug 2014 12:20:37 +0000 (+0200) Subject: conf: cpupin: Remove useless checking of vcpupin element count X-Git-Tag: v1.2.8-rc1~99 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=cb8a94bfa037b12b1c1896bd3c02f5bf6746d9e1;p=thirdparty%2Flibvirt.git conf: cpupin: Remove useless checking of vcpupin element count The check doesn't make much sense as right below it the entries are either checked for duplicity or ignored in some cases. Having this check doesn't actually forbid passing invalid values. --- diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index 5c762fab40..82f3ee6688 100644 --- a/src/conf/domain_conf.c +++ b/src/conf/domain_conf.c @@ -11993,12 +11993,6 @@ virDomainDefParseXML(xmlDocPtr xml, if (n && VIR_ALLOC_N(def->cputune.vcpupin, n) < 0) goto error; - if (n > def->maxvcpus) { - virReportError(VIR_ERR_INTERNAL_ERROR, - "%s", _("vcpupin nodes must be less than maxvcpus")); - goto error; - } - for (i = 0; i < n; i++) { virDomainVcpuPinDefPtr vcpupin = NULL; vcpupin = virDomainVcpuPinDefParseXML(nodes[i], ctxt, def->maxvcpus, 0);