mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-02-14 23:51:29 +00:00
virstring: Drop VIR_AUTOSTRINGLIST
Now that no one uses VIR_AUTOSTRINGLIST it can be dropped. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> Reviewed-by: Ján Tomko <jtomko@redhat.com>
This commit is contained in:
parent
b7d4e6b67e
commit
a2196bc238
@ -3227,7 +3227,6 @@ virStringHasSuffix;
|
||||
virStringIsEmpty;
|
||||
virStringIsPrintable;
|
||||
virStringListAdd;
|
||||
virStringListAutoFree;
|
||||
virStringListFreeCount;
|
||||
virStringListGetFirstWithPrefix;
|
||||
virStringListHasString;
|
||||
|
@ -259,16 +259,6 @@ virStringListMerge(char ***dst,
|
||||
}
|
||||
|
||||
|
||||
void virStringListAutoFree(char ***strings)
|
||||
{
|
||||
if (!*strings)
|
||||
return;
|
||||
|
||||
g_strfreev(*strings);
|
||||
*strings = NULL;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* virStringListFreeCount:
|
||||
* @strings: array of strings to free
|
||||
|
@ -45,7 +45,6 @@ void virStringListRemove(char ***strings,
|
||||
int virStringListMerge(char ***dst,
|
||||
char ***src);
|
||||
|
||||
void virStringListAutoFree(char ***strings);
|
||||
void virStringListFreeCount(char **strings,
|
||||
size_t count);
|
||||
|
||||
@ -179,11 +178,3 @@ int virStringParsePort(const char *str,
|
||||
int virStringParseYesNo(const char *str,
|
||||
bool *result)
|
||||
G_GNUC_WARN_UNUSED_RESULT;
|
||||
/**
|
||||
* VIR_AUTOSTRINGLIST:
|
||||
*
|
||||
* Declares a NULL-terminated list of strings which will be automatically freed
|
||||
* when the pointer goes out of scope.
|
||||
*/
|
||||
#define VIR_AUTOSTRINGLIST \
|
||||
__attribute__((cleanup(virStringListAutoFree))) char **
|
||||
|
Loading…
x
Reference in New Issue
Block a user