From: Daniel P. Berrange Date: Wed, 19 Dec 2012 10:49:30 +0000 (+0000) Subject: Fix parsing of arch from domain XML X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=1c212145a3859ddf1e333ae8a200101041872b9b;p=libvirt.git Fix parsing of arch from domain XML When parsing the arch from domain XML, the result was only saved to a local variable, not the virDomainDefPtr Signed-off-by: Daniel P. Berrange --- diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index ba70e0292d..ccb3b635d0 100644 --- a/src/conf/domain_conf.c +++ b/src/conf/domain_conf.c @@ -9576,8 +9576,8 @@ static virDomainDefPtr virDomainDefParseXML(virCapsPtr caps, tmp = virXPathString("string(./os/type[1]/@arch)", ctxt); if (tmp) { - virArch arch = virArchFromString(tmp); - if (!arch) { + def->os.arch = virArchFromString(tmp); + if (!def->os.arch) { virReportError(VIR_ERR_CONFIG_UNSUPPORTED, _("Unknown architecture %s"), tmp);