mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-11 15:27:47 +00:00
util: uri: Introduce VIR_AUTOPTR freeing function
Signed-off-by: Peter Krempa <pkrempa@redhat.com> Reviewed-by: Ján Tomko <jtomko@redhat.com>
This commit is contained in:
parent
e8ef1dd174
commit
46bd9ee7d7
@ -25,6 +25,7 @@
|
||||
|
||||
# include "internal.h"
|
||||
# include "virconf.h"
|
||||
# include "virautoclean.h"
|
||||
|
||||
typedef struct _virURI virURI;
|
||||
typedef virURI *virURIPtr;
|
||||
@ -60,6 +61,7 @@ char *virURIFormat(virURIPtr uri)
|
||||
char *virURIFormatParams(virURIPtr uri);
|
||||
|
||||
void virURIFree(virURIPtr uri);
|
||||
VIR_DEFINE_AUTOPTR_FUNC(virURI, virURIFree);
|
||||
int virURIResolveAlias(virConfPtr conf, const char *alias, char **uri);
|
||||
|
||||
# define VIR_URI_SERVER(uri) ((uri) && (uri)->server ? (uri)->server : "localhost")
|
||||
|
Loading…
Reference in New Issue
Block a user