network: address: expose address_flags_to_string_alloc()

This commit is contained in:
Yu Watanabe
2021-11-25 22:35:35 +09:00
parent 7314084aa4
commit 42ceb47456
2 changed files with 3 additions and 1 deletions
+1 -1
View File
@@ -24,7 +24,7 @@
#define ADDRESSES_PER_LINK_MAX 2048U
#define STATIC_ADDRESSES_PER_NETWORK_MAX 1024U
static int address_flags_to_string_alloc(uint32_t flags, int family, char **ret) {
int address_flags_to_string_alloc(uint32_t flags, int family, char **ret) {
_cleanup_free_ char *str = NULL;
static const struct {
uint32_t flag;
+2
View File
@@ -61,6 +61,8 @@ const char* format_lifetime(char *buf, size_t l, usec_t lifetime_usec) _warn_unu
#define FORMAT_LIFETIME(lifetime) \
format_lifetime((char[FORMAT_TIMESPAN_MAX+STRLEN("for ")]){}, FORMAT_TIMESPAN_MAX+STRLEN("for "), lifetime)
int address_flags_to_string_alloc(uint32_t flags, int family, char **ret);
int address_new(Address **ret);
Address* address_free(Address *address);
int address_get(Link *link, const Address *in, Address **ret);