summaryrefslogtreecommitdiff
path: root/src/resolve
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2014-07-18 13:59:49 +0200
committerLennart Poettering <lennart@poettering.net>2014-07-18 14:01:01 +0200
commit3c0cf502796be355431d4a64d738e75f543aa51d (patch)
treecf487855d985e3405b374022abc6b17a22261140 /src/resolve
parent3f8916fb0dd9eb8c4c4979045d3e2b223f776698 (diff)
resolved: add more const
Diffstat (limited to 'src/resolve')
-rw-r--r--src/resolve/resolved-dns-server.c2
-rw-r--r--src/resolve/resolved-dns-server.h11
2 files changed, 7 insertions, 6 deletions
diff --git a/src/resolve/resolved-dns-server.c b/src/resolve/resolved-dns-server.c
index 4e0220b7d8..07754a0bdb 100644
--- a/src/resolve/resolved-dns-server.c
+++ b/src/resolve/resolved-dns-server.c
@@ -27,7 +27,7 @@ int dns_server_new(
DnsServerSource source,
Link *l,
unsigned char family,
- union in_addr_union *in_addr) {
+ const union in_addr_union *in_addr) {
DnsServer *s, *tail;
diff --git a/src/resolve/resolved-dns-server.h b/src/resolve/resolved-dns-server.h
index adceb868a3..781e237627 100644
--- a/src/resolve/resolved-dns-server.h
+++ b/src/resolve/resolved-dns-server.h
@@ -21,10 +21,11 @@
along with systemd; If not, see <http://www.gnu.org/licenses/>.
***/
+#include "in-addr-util.h"
+
typedef struct DnsServer DnsServer;
typedef enum DnsServerSource DnsServerSource;
-#include "in-addr-util.h"
#include "resolved.h"
#include "resolved-link.h"
#include "resolved-dns-server.h"
@@ -40,12 +41,12 @@ struct DnsServer {
Manager *manager;
DnsServerSource source;
+ Link *link;
+
unsigned char family;
union in_addr_union address;
- bool marked;
-
- Link *link;
+ bool marked:1;
LIST_FIELDS(DnsServer, servers);
};
@@ -56,6 +57,6 @@ int dns_server_new(
DnsServerSource source,
Link *l,
unsigned char family,
- union in_addr_union *in_addr);
+ const union in_addr_union *address);
DnsServer* dns_server_free(DnsServer *s);