Adds:
- New struct virNetworkEventMetadataChange.
- virNetworkEvent*Dispose() function for the same.
Signed-off-by: K Shiva Kiran <shiva_kr(a)riseup.net>
---
src/conf/network_event.c | 24 ++++++++++++++++++++++++
1 file changed, 24 insertions(+)
diff --git a/src/conf/network_event.c b/src/conf/network_event.c
index 6f25e43711..51fa092ffd 100644
--- a/src/conf/network_event.c
+++ b/src/conf/network_event.c
@@ -45,10 +45,21 @@ struct _virNetworkEventLifecycle {
};
typedef struct _virNetworkEventLifecycle virNetworkEventLifecycle;
+struct _virNetworkEventMetadataChange {
+ virNetworkEvent parent;
+
+ int type;
+ char *nsuri;
+};
+typedef struct _virNetworkEventMetadataChange virNetworkEventMetadataChange;
+
static virClass *virNetworkEventClass;
static virClass *virNetworkEventLifecycleClass;
+static virClass *virNetworkEventMetadataChangeClass;
+
static void virNetworkEventDispose(void *obj);
static void virNetworkEventLifecycleDispose(void *obj);
+static void virNetworkEventMetadataChangeDispose(void *obj);
static int
virNetworkEventsOnceInit(void)
@@ -59,6 +70,9 @@ virNetworkEventsOnceInit(void)
if (!VIR_CLASS_NEW(virNetworkEventLifecycle, virNetworkEventClass))
return -1;
+ if (!VIR_CLASS_NEW(virNetworkEventMetadataChange, virNetworkEventClass))
+ return -1;
+
return 0;
}
@@ -231,3 +245,13 @@ virNetworkEventLifecycleNew(const char *name,
return (virObjectEvent *)event;
}
+
+
+static void
+virNetworkEventMetadataChangeDispose(void *obj)
+{
+ virNetworkEventMetadataChange *event = obj;
+ VIR_DEBUG("obj=%p", event);
+
+ g_free(event->nsuri);
+}
--
2.42.0