From: Chris Lalancette Date: Wed, 28 Apr 2010 19:49:41 +0000 (-0400) Subject: Fix a qemuDomainPCIAddressSetFree memory leak X-Git-Tag: v0.8.1~19 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=87d2e4ba56e6e592c7c5d7f919be719e19b07693;p=thirdparty%2Flibvirt.git Fix a qemuDomainPCIAddressSetFree memory leak qemuDomainPCIAddressSetFree was freeing up the hash table for the pci addresses, but not freeing up the addr structure. Looking over the callers of this function, it seems like they expect it to also free up the structure, so do that here. Signed-off-by: Chris Lalancette --- diff --git a/src/qemu/qemu_conf.c b/src/qemu/qemu_conf.c index ed24916a0c..5fa8c0aa18 100644 --- a/src/qemu/qemu_conf.c +++ b/src/qemu/qemu_conf.c @@ -2110,7 +2110,7 @@ void qemuDomainPCIAddressSetFree(qemuDomainPCIAddressSetPtr addrs) return; virHashFree(addrs->used, qemuDomainPCIAddressSetFreeEntry); - addrs->used = NULL; + VIR_FREE(addrs); }