From: Wei Liu Date: Sun, 14 Dec 2014 14:58:17 +0000 (+0000) Subject: xenconfig: fix boot device parsing X-Git-Tag: v1.2.12-rc1~195 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=64b0484cad3e591d9697b1cfe98cac4c614ea604;p=thirdparty%2Flibvirt.git xenconfig: fix boot device parsing The original code always checked *boot which was in effect boot[0]. It should use boot[i]. Signed-off-by: Wei Liu --- diff --git a/src/xenconfig/xen_common.c b/src/xenconfig/xen_common.c index 33ac127efe..25bdf26cc0 100644 --- a/src/xenconfig/xen_common.c +++ b/src/xenconfig/xen_common.c @@ -1071,7 +1071,7 @@ xenParseOS(virConfPtr conf, virDomainDefPtr def) return -1; for (i = 0; i < VIR_DOMAIN_BOOT_LAST && boot[i]; i++) { - switch (*boot) { + switch (boot[i]) { case 'a': def->os.bootDevs[i] = VIR_DOMAIN_BOOT_FLOPPY; break;