mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-02-22 11:22:23 +00:00
Fixed PXE network boot config
This commit is contained in:
parent
cc82a93645
commit
63dc047468
@ -1,3 +1,11 @@
|
||||
Thu Sep 13 17:58:00 EST 2007 Daniel P. Berrange <berrange@redhat.com>
|
||||
|
||||
* src/qemu_conf.c: Fix handling of <boot> tag for network PXE
|
||||
* tests/qemuxml2argvdata/qemuxml2argv-boot-network.xml: Fix test
|
||||
for network PXE boot element
|
||||
* tests/qemuxml2argvtest.c, tests/qemuxml2xmltest.c: Fixed potential
|
||||
SEGV crash in error case cleanup
|
||||
|
||||
Wed Sep 12 16:35:00 BST 2007 Richard W.M. Jones <rjones@redhat.com>
|
||||
|
||||
* src/xend_internal.c, src/xml.c, src/xml.h: Properly check buffer
|
||||
|
@ -1180,7 +1180,7 @@ static struct qemud_vm_def *qemudParseXML(virConnectPtr conn,
|
||||
def->os.bootDevs[def->os.nBootDevs++] = QEMUD_BOOT_FLOPPY;
|
||||
} else if (!strcmp((char *)prop, "cdrom")) {
|
||||
def->os.bootDevs[def->os.nBootDevs++] = QEMUD_BOOT_CDROM;
|
||||
} else if (!strcmp((char *)prop, "net")) {
|
||||
} else if (!strcmp((char *)prop, "network")) {
|
||||
def->os.bootDevs[def->os.nBootDevs++] = QEMUD_BOOT_NET;
|
||||
} else {
|
||||
goto error;
|
||||
@ -2819,7 +2819,7 @@ char *qemudGenerateXML(virConnectPtr conn,
|
||||
boottype = "cdrom";
|
||||
break;
|
||||
case QEMUD_BOOT_NET:
|
||||
boottype = "net";
|
||||
boottype = "network";
|
||||
break;
|
||||
}
|
||||
if (virBufferVSprintf(buf, " <boot dev='%s'/>\n", boottype) < 0)
|
||||
|
@ -6,7 +6,7 @@
|
||||
<vcpu>1</vcpu>
|
||||
<os>
|
||||
<type arch='i686' machine='pc'>hvm</type>
|
||||
<boot dev='net'/>
|
||||
<boot dev='network'/>
|
||||
</os>
|
||||
<clock offset='utc'/>
|
||||
<on_poweroff>destroy</on_poweroff>
|
||||
|
@ -79,8 +79,8 @@ static int testCompareXMLToArgvFiles(const char *xml, const char *cmd) {
|
||||
}
|
||||
free(argv);
|
||||
}
|
||||
|
||||
qemudFreeVMDef(vmdef);
|
||||
if (vmdef)
|
||||
qemudFreeVMDef(vmdef);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
@ -48,7 +48,8 @@ static int testCompareXMLToXMLFiles(const char *xml) {
|
||||
|
||||
fail:
|
||||
free(actual);
|
||||
qemudFreeVMDef(vmdef);
|
||||
if (vmdef)
|
||||
qemudFreeVMDef(vmdef);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user