[PATCH v3 05/16] interface: Use virObjectLookupKeys

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

 



Use the virObjectLookupKeys rather than virObjectLockable.

Signed-off-by: John Ferlan <jferlan@xxxxxxxxxx>
---
 src/conf/virinterfaceobj.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/conf/virinterfaceobj.c b/src/conf/virinterfaceobj.c
index 106f232..243ff33 100644
--- a/src/conf/virinterfaceobj.c
+++ b/src/conf/virinterfaceobj.c
@@ -33,7 +33,7 @@
 VIR_LOG_INIT("conf.virinterfaceobj");
 
 struct _virInterfaceObj {
-    virObjectLockable parent;
+    virObjectLookupKeys parent;
 
     bool active;           /* true if interface is active (up) */
     virInterfaceDefPtr def; /* The interface definition */
@@ -52,7 +52,7 @@ static void virInterfaceObjDispose(void *obj);
 static int
 virInterfaceObjOnceInit(void)
 {
-    if (!(virInterfaceObjClass = virClassNew(virClassForObjectLockable(),
+    if (!(virInterfaceObjClass = virClassNew(virClassForObjectLookupKeys(),
                                              "virInterfaceObj",
                                              sizeof(virInterfaceObj),
                                              virInterfaceObjDispose)))
@@ -81,7 +81,7 @@ virInterfaceObjNew(virInterfaceDefPtr def)
     if (virInterfaceObjInitialize() < 0)
         return NULL;
 
-    if (!(obj = virObjectLockableNew(virInterfaceObjClass)))
+    if (!(obj = virObjectLookupKeysNew(virInterfaceObjClass, NULL, def->name)))
         return NULL;
 
     virObjectLock(obj);
-- 
2.9.4

--
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]
  Powered by Linux