summaryrefslogtreecommitdiff
path: root/src/resolve/resolved-dns-query.h
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2015-11-26 22:51:35 +0100
committerLennart Poettering <lennart@poettering.net>2015-11-27 00:03:39 +0100
commitae6a4bbf318e197813227e50c245a00de03784a2 (patch)
tree94a1761cfa4e445ed820e2cccd01dde7d2949e55 /src/resolve/resolved-dns-query.h
parentb05f5ae7c5a95f44a59e5d2251879d0ef2af9cb2 (diff)
resolved: store just the DnsAnswer instead of a DnsPacket as answer in DnsTransaction objects
Previously we'd only store the DnsPacket in the DnsTransaction, and the DnsQuery would then take the DnsPacket's DnsAnswer and return it. With this change we already pull the DnsAnswer out inside the transaction. We still store the DnsPacket in the transaction, if we have it, since we still need to determine from which peer a response originates, to implement caching properly. However, the DnsQuery logic doesn't care anymore for the packet, it now only looks at answers and rcodes from the successfuly candidate. This also has the benefit of unifying how we propagate incoming packets, data from the local zone or the local cache.
Diffstat (limited to 'src/resolve/resolved-dns-query.h')
-rw-r--r--src/resolve/resolved-dns-query.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/resolve/resolved-dns-query.h b/src/resolve/resolved-dns-query.h
index fb16747c55..a9d7904a8d 100644
--- a/src/resolve/resolved-dns-query.h
+++ b/src/resolve/resolved-dns-query.h
@@ -71,9 +71,9 @@ struct DnsQuery {
/* Discovered data */
DnsAnswer *answer;
- int answer_family;
- DnsProtocol answer_protocol;
int answer_rcode;
+ DnsProtocol answer_protocol;
+ int answer_family;
DnsSearchDomain *answer_search_domain;
/* Bus client information */