[PATCH 03/11] Rename all APIs in lxc_domain.c to have a virLXCDomain prefix

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

 



From: "Daniel P. Berrange" <berrange@xxxxxxxxxx>

For consistency all the APIs in the lxc_domain.c file should
have a virLXCDomain prefix in their name

Signed-off-by: Daniel P. Berrange <berrange@xxxxxxxxxx>
---
 src/lxc/lxc_domain.c  |   14 +++++++-------
 src/lxc/lxc_domain.h  |    8 ++++----
 src/lxc/lxc_driver.c  |    2 +-
 src/lxc/lxc_process.c |    8 ++++----
 4 files changed, 16 insertions(+), 16 deletions(-)

diff --git a/src/lxc/lxc_domain.c b/src/lxc/lxc_domain.c
index f78dc09..847aac7 100644
--- a/src/lxc/lxc_domain.c
+++ b/src/lxc/lxc_domain.c
@@ -25,9 +25,9 @@
 
 #include "memory.h"
 
-static void *lxcDomainObjPrivateAlloc(void)
+static void *virLXCDomainObjPrivateAlloc(void)
 {
-    lxcDomainObjPrivatePtr priv;
+    virLXCDomainObjPrivatePtr priv;
 
     if (VIR_ALLOC(priv) < 0)
         return NULL;
@@ -38,16 +38,16 @@ static void *lxcDomainObjPrivateAlloc(void)
     return priv;
 }
 
-static void lxcDomainObjPrivateFree(void *data)
+static void virLXCDomainObjPrivateFree(void *data)
 {
-    lxcDomainObjPrivatePtr priv = data;
+    virLXCDomainObjPrivatePtr priv = data;
 
     VIR_FREE(priv);
 }
 
 
-void lxcDomainSetPrivateDataHooks(virCapsPtr caps)
+void virLXCDomainSetPrivateDataHooks(virCapsPtr caps)
 {
-    caps->privateDataAllocFunc = lxcDomainObjPrivateAlloc;
-    caps->privateDataFreeFunc = lxcDomainObjPrivateFree;
+    caps->privateDataAllocFunc = virLXCDomainObjPrivateAlloc;
+    caps->privateDataFreeFunc = virLXCDomainObjPrivateFree;
 }
diff --git a/src/lxc/lxc_domain.h b/src/lxc/lxc_domain.h
index 9629465..8a2c892 100644
--- a/src/lxc/lxc_domain.h
+++ b/src/lxc/lxc_domain.h
@@ -25,13 +25,13 @@
 
 # include "lxc_conf.h"
 
-typedef struct _lxcDomainObjPrivate lxcDomainObjPrivate;
-typedef lxcDomainObjPrivate *lxcDomainObjPrivatePtr;
-struct _lxcDomainObjPrivate {
+typedef struct _virLXCDomainObjPrivate virLXCDomainObjPrivate;
+typedef virLXCDomainObjPrivate *virLXCDomainObjPrivatePtr;
+struct _virLXCDomainObjPrivate {
     int monitor;
     int monitorWatch;
 };
 
-void lxcDomainSetPrivateDataHooks(virCapsPtr caps);
+void virLXCDomainSetPrivateDataHooks(virCapsPtr caps);
 
 #endif /* __LXC_DOMAIN_H__ */
diff --git a/src/lxc/lxc_driver.c b/src/lxc/lxc_driver.c
index 8416e15..fc6190b 100644
--- a/src/lxc/lxc_driver.c
+++ b/src/lxc/lxc_driver.c
@@ -1434,7 +1434,7 @@ static int lxcStartup(int privileged)
     if ((lxc_driver->caps = lxcCapsInit(lxc_driver)) == NULL)
         goto cleanup;
 
-    lxcDomainSetPrivateDataHooks(lxc_driver->caps);
+    virLXCDomainSetPrivateDataHooks(lxc_driver->caps);
 
     if (virLXCProcessAutoDestroyInit(lxc_driver) < 0)
         goto cleanup;
diff --git a/src/lxc/lxc_process.c b/src/lxc/lxc_process.c
index c25a04b..c630136 100644
--- a/src/lxc/lxc_process.c
+++ b/src/lxc/lxc_process.c
@@ -161,7 +161,7 @@ static void virLXCProcessCleanup(lxc_driver_t *driver,
 {
     virCgroupPtr cgroup;
     int i;
-    lxcDomainObjPrivatePtr priv = vm->privateData;
+    virLXCDomainObjPrivatePtr priv = vm->privateData;
     virNetDevVPortProfilePtr vport = NULL;
 
     /* now that we know it's stopped call the hook if present */
@@ -590,7 +590,7 @@ static void virLXCProcessMonitorEvent(int watch,
     lxc_driver_t *driver = lxc_driver;
     virDomainObjPtr vm = data;
     virDomainEventPtr event = NULL;
-    lxcDomainObjPrivatePtr priv;
+    virLXCDomainObjPrivatePtr priv;
 
     lxcDriverLock(driver);
     virDomainObjLock(vm);
@@ -807,7 +807,7 @@ int virLXCProcessStart(virConnectPtr conn,
     char ebuf[1024];
     char *timestamp;
     virCommandPtr cmd = NULL;
-    lxcDomainObjPrivatePtr priv = vm->privateData;
+    virLXCDomainObjPrivatePtr priv = vm->privateData;
     virErrorPtr err = NULL;
 
     if (!lxc_driver->cgroup) {
@@ -1178,7 +1178,7 @@ virLXCProcessReconnectDomain(void *payload, const void *name ATTRIBUTE_UNUSED, v
 {
     virDomainObjPtr vm = payload;
     lxc_driver_t *driver = opaque;
-    lxcDomainObjPrivatePtr priv;
+    virLXCDomainObjPrivatePtr priv;
 
     virDomainObjLock(vm);
     VIR_DEBUG("Reconnect %d %d %d\n", vm->def->id, vm->pid, vm->state.state);
-- 
1.7.10.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]