mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-03-07 17:28:15 +00:00
conf: convert network_conf.c to use g_auto* pointers
This was mostly boilerplate conversion, but in one case I needed to define several differently named char* to take the place of a single char *tmp that was re-used multiple times, and in another place there was a single char* that was used at the toplevel of the function, and then later used repeatedly inside a for loop, so I defined a new separate char* inside the loop. Signed-off-by: Laine Stump <laine@redhat.com> Reviewed-by: Erik Skultety <eskultet@redhat.com>
This commit is contained in:
parent
8a4f331e8c
commit
257aba2daf
File diff suppressed because it is too large
Load Diff
@ -321,6 +321,7 @@ typedef enum {
|
||||
} virNetworkTaintFlags;
|
||||
|
||||
void virNetworkDefFree(virNetworkDefPtr def);
|
||||
G_DEFINE_AUTOPTR_CLEANUP_FUNC(virNetworkDef, virNetworkDefFree);
|
||||
|
||||
enum {
|
||||
VIR_NETWORK_OBJ_LIST_ADD_LIVE = (1 << 0),
|
||||
|
@ -247,6 +247,7 @@ G_DEFINE_AUTO_CLEANUP_CLEAR_FUNC(virXPathContextNodeSave, virXPathContextNodeRes
|
||||
|
||||
G_DEFINE_AUTOPTR_CLEANUP_FUNC(xmlDoc, xmlFreeDoc);
|
||||
G_DEFINE_AUTOPTR_CLEANUP_FUNC(xmlXPathContext, xmlXPathFreeContext);
|
||||
G_DEFINE_AUTOPTR_CLEANUP_FUNC(xmlBuffer, xmlBufferFree);
|
||||
|
||||
typedef int (*virXMLNamespaceParse)(xmlXPathContextPtr ctxt, void **nsdata);
|
||||
typedef void (*virXMLNamespaceFree)(void *nsdata);
|
||||
|
Loading…
x
Reference in New Issue
Block a user