]> git.ipfire.org Git - thirdparty/libvirt.git/commit
qemu: fix infinite loop in OOM error path
authorLaine Stump <laine@laine.org>
Tue, 25 Jun 2013 02:42:35 +0000 (22:42 -0400)
committerLaine Stump <laine@laine.org>
Tue, 25 Jun 2013 22:24:56 +0000 (18:24 -0400)
commita47b9e879c486124ab9e0ecde97ef2275e382306
treeb9f1d5cce7b9aaacb601483e483ff2e3877bbd28
parentb2a2d00f5792c6af3b4a159617216191d783a6cd
qemu: fix infinite loop in OOM error path

A loop in qemuPrepareHostdevPCIDevices() intended to cycle through all
the objects on the list pcidevs was doing "while (listcount > 0)", but
nothing in the body of the loop was reducing the size of the list - it
was instead removing items from a *different* list. It has now been
safely changed to a for() loop.
src/qemu/qemu_hostdev.c