Fixed crash prossing input tags

This commit is contained in:
Daniel P. Berrange 2007-09-28 20:47:58 +00:00
parent 4bf3bc9eda
commit b876bf6ea5
2 changed files with 5 additions and 1 deletions

View File

@ -1,3 +1,7 @@
Fri Sep 28 16:41:41 EST 2007 Daniel P. Berrange <berrange@redhat.com>
* src/qemu_conf.c: Fix crash processing multiple <input> tags
Fri Sep 28 16:17:41 CEST 2007 Daniel Veillard <veillard@redhat.com>
* include/libvirt/libvirt.h[.in] src/driver.h src/openvz_driver.c

View File

@ -1312,7 +1312,7 @@ static struct qemud_vm_def *qemudParseXML(virConnectPtr conn,
}
def->ninputs++;
input->next = NULL;
if (i == 0) {
if (def->inputs == NULL) {
def->inputs = input;
} else {
prev->next = input;