[PATCH 07/18] vz: fix memory leaks in attach/detach functions

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Signed-off-by: Nikolay Shirokovskiy <nshirokovskiy@xxxxxxxxxxxxx>
---
 src/vz/vz_driver.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/src/vz/vz_driver.c b/src/vz/vz_driver.c
index b007ad2..ea28698 100644
--- a/src/vz/vz_driver.c
+++ b/src/vz/vz_driver.c
@@ -1131,6 +1131,7 @@ static int vzDomainAttachDeviceFlags(virDomainPtr dom, const char *xml,
 
     ret = 0;
  cleanup:
+    virDomainDeviceDefFree(dev);
     virObjectUnlock(privdom);
     return ret;
 }
@@ -1170,6 +1171,7 @@ static int vzDomainDetachDeviceFlags(virDomainPtr dom, const char *xml,
 
     ret = 0;
  cleanup:
+    virDomainDeviceDefFree(dev);
     virObjectUnlock(privdom);
 
     return ret;
-- 
1.8.3.1

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list



[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]