mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-03-22 14:50:27 +03:00
qemu: Using virStringListFreeCount instead VIR_FREE to free tmpPaths.
The function qemuDomainGetHostdevPath() is using VIR_FREE to free the paths stored in tmpPaths. Both syntax analyzer are reporting a warning about this. Replacing the old method to function virStringListFreeCount() fixes the warnings/errors. Signed-off-by: Julio Faracco <jcfaracco@gmail.com> Reviewed-by: John Ferlan <jferlan@redhat.com>
This commit is contained in:
parent
83405f92a9
commit
870282cb43
@ -11132,9 +11132,7 @@ qemuDomainGetHostdevPath(virDomainDefPtr def,
|
||||
}
|
||||
ret = 0;
|
||||
cleanup:
|
||||
for (i = 0; i < tmpNpaths; i++)
|
||||
VIR_FREE(tmpPaths[i]);
|
||||
VIR_FREE(tmpPaths);
|
||||
virStringListFreeCount(tmpPaths, tmpNpaths);
|
||||
VIR_FREE(tmpPerms);
|
||||
virPCIDeviceFree(pci);
|
||||
virUSBDeviceFree(usb);
|
||||
|
Loading…
x
Reference in New Issue
Block a user