Free cgroup device ACL list on driver shutdown

* src/qemu/qemu_driver.c: Free cgroup ACLs
This commit is contained in:
Daniel P. Berrange 2009-11-24 11:44:23 +00:00
parent 7cfbb17978
commit db810b1148

View File

@ -1071,6 +1071,7 @@ qemudActive(void) {
*/
static int
qemudShutdown(void) {
int i;
if (!qemu_driver)
return -1;
@ -1096,6 +1097,12 @@ qemudShutdown(void) {
VIR_FREE(qemu_driver->hugetlbfs_mount);
VIR_FREE(qemu_driver->hugepage_path);
if (qemu_driver->cgroupDeviceACL) {
for (i = 0 ; qemu_driver->cgroupDeviceACL[i] != NULL ; i++)
VIR_FREE(qemu_driver->cgroupDeviceACL[i]);
VIR_FREE(qemu_driver->cgroupDeviceACL);
}
/* Free domain callback list */
virDomainEventCallbackListFree(qemu_driver->domainEventCallbacks);
virDomainEventQueueFree(qemu_driver->domainEventQueue);