mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-22 21:55:25 +00:00
Rename all APIs in lxc_domain.c to have a virLXCDomain prefix
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@redhat.com>
This commit is contained in:
parent
eaf10b84ed
commit
ced272efc5
@ -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;
|
||||
}
|
||||
|
@ -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__ */
|
||||
|
@ -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;
|
||||
|
@ -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);
|
||||
|
Loading…
Reference in New Issue
Block a user