[libvirt-designer 3/7] virtxml: Don't leak 'iface' in add_iface()

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

 



The caller of gvir_designer_domain_add_interface_network() owns a reference
on the returned GVirConfigDomainInterface instance, so it needs to be
released when no longer needed.
---
 examples/virt-designer.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/examples/virt-designer.c b/examples/virt-designer.c
index 7628449..f134b98 100644
--- a/examples/virt-designer.c
+++ b/examples/virt-designer.c
@@ -350,6 +350,7 @@ add_iface(gpointer data,
             exit(EXIT_FAILURE);
         }
     }
+    g_object_unref(iface);
 }
 
 static gboolean
-- 
2.1.0

--
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]