implement pkgconf_cross_personality_deinit

master
Stone Tickle 2021-06-11 15:00:47 +09:00 committed by Ariadne Conill
parent 13fe4c8c58
commit d688a7bd03
2 changed files with 9 additions and 0 deletions

View File

@ -231,6 +231,7 @@ PKGCONF_API void pkgconf_client_dir_list_build(pkgconf_client_t *client, const p
/* personality.c */ /* personality.c */
PKGCONF_API pkgconf_cross_personality_t *pkgconf_cross_personality_default(void); PKGCONF_API pkgconf_cross_personality_t *pkgconf_cross_personality_default(void);
PKGCONF_API pkgconf_cross_personality_t *pkgconf_cross_personality_find(const char *triplet); PKGCONF_API pkgconf_cross_personality_t *pkgconf_cross_personality_find(const char *triplet);
PKGCONF_API void pkgconf_cross_personality_deinit(pkgconf_cross_personality_t *personality);
#define PKGCONF_IS_MODULE_SEPARATOR(c) ((c) == ',' || isspace ((unsigned int)(c))) #define PKGCONF_IS_MODULE_SEPARATOR(c) ((c) == ',' || isspace ((unsigned int)(c)))
#define PKGCONF_IS_OPERATOR_CHAR(c) ((c) == '<' || (c) == '>' || (c) == '!' || (c) == '=') #define PKGCONF_IS_OPERATOR_CHAR(c) ((c) == '<' || (c) == '>' || (c) == '!' || (c) == '=')

View File

@ -103,6 +103,14 @@ pkgconf_cross_personality_default(void)
return &default_personality; return &default_personality;
} }
void
pkgconf_cross_personality_deinit(pkgconf_cross_personality_t *personality)
{
pkgconf_path_free(&personality->dir_list);
pkgconf_path_free(&personality->filter_libdirs);
pkgconf_path_free(&personality->filter_includedirs);
}
#ifndef PKGCONF_LITE #ifndef PKGCONF_LITE
static bool static bool
valid_triplet(const char *triplet) valid_triplet(const char *triplet)