diff options
author | Tom Gundersen <teg@jklm.no> | 2014-07-23 23:03:50 +0200 |
---|---|---|
committer | Tom Gundersen <teg@jklm.no> | 2014-07-23 23:54:52 +0200 |
commit | 6f4dedb250f2d607eceefaa491f338becbeee7c0 (patch) | |
tree | 88ee8549eeb089e853ffce1640f9cb23705a3a5a /src/systemd | |
parent | 6073b6f26ab9fc6bf335faa7073ec443eef093fd (diff) | |
download | systemd-6f4dedb250f2d607eceefaa491f338becbeee7c0.tar.gz |
sd-network: expose DNS/NTP servers as strings
This avoids having to distinguish between IPv4 and IPv6, allowing us
to keep their internal orderings. The consumers now has to turn the
strings into addresses.
Diffstat (limited to 'src/systemd')
-rw-r--r-- | src/systemd/sd-network.h | 16 |
1 files changed, 6 insertions, 10 deletions
diff --git a/src/systemd/sd-network.h b/src/systemd/sd-network.h index e4547057f1..ec01e07e85 100644 --- a/src/systemd/sd-network.h +++ b/src/systemd/sd-network.h @@ -76,17 +76,13 @@ int sd_network_get_operational_state(char **state); /* Get DHCPv4 lease from ifindex. */ int sd_network_get_dhcp_lease(int ifindex, sd_dhcp_lease **ret); -/* Returns true if link is configured to respect DNS entries received by DHCP */ -int sd_network_dhcp_use_dns(int ifindex); +/* Get DNS entries for a given link. These are string representations of + * IP addresses */ +int sd_network_get_dns(int ifindex, char ***addr); -/* Returns true if link is configured to respect NTP entries received by DHCP */ -int sd_network_dhcp_use_ntp(int ifindex); - -/* Get IPv4 DNS entries statically configured for the link */ -int sd_network_get_dns(int ifindex, struct in_addr **addr); - -/* Get IPv6 DNS entries statically configured for the link */ -int sd_network_get_dns6(int ifindex, struct in6_addr **addr); +/* Get NTP entries for a given link. These are domain names or string + * reperesentations of IP addresses */ +int sd_network_get_ntp(int ifindex, char ***addr); /* Monitor object */ typedef struct sd_network_monitor sd_network_monitor; |