util: avoid memory leak

Leak in pciGetVirtualFunctionIndex present since commit 17d64ca.

* src/util/pci.c: fix memory leak.

Signed-off-by: Alex Jia <ajia@redhat.com>
This commit is contained in:
ajia@redhat.com 2011-09-19 00:36:13 +08:00 committed by Eric Blake
parent 809999b5a3
commit d02c4a1877

View File

@ -1965,6 +1965,7 @@ out:
for (i = 0; i < num_virt_fns; i++)
VIR_FREE(virt_fns[i]);
VIR_FREE(virt_fns);
VIR_FREE(vf_bdf);
return ret;