Merge pull request #34546 from ikruglov/ikruglov/refactor-GetMachineAddresses

machine: generalise logic of GetMachineAddresses/GetOsRelease to later use it in corresponding varlink interfaces
This commit is contained in:
Daan De Meyer
2024-10-02 10:24:59 +02:00
committed by GitHub
5 changed files with 265 additions and 224 deletions
+1 -1
View File
@@ -104,7 +104,7 @@ static int add_local_address_full(
return 1;
}
static int add_local_address(
int add_local_address(
struct local_address **list,
size_t *n_list,
int ifindex,
+2
View File
@@ -16,6 +16,8 @@ struct local_address {
bool has_local_address(const struct local_address *addresses, size_t n_addresses, const struct local_address *needle);
int add_local_address(struct local_address **list, size_t *n_list, int ifindex, unsigned char scope, int family, const union in_addr_union *address);
int local_addresses(sd_netlink *rtnl, int ifindex, int af, struct local_address **ret);
int local_gateways(sd_netlink *rtnl, int ifindex, int af, struct local_address **ret);