summaryrefslogtreecommitdiff
path: root/src/resolve/resolved-dns-scope.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2015-08-21 22:55:01 +0200
committerLennart Poettering <lennart@poettering.net>2015-08-21 22:55:01 +0200
commitf52e61da047d7fc74e83f12dbbf87e0cbcc51c73 (patch)
tree477d5ab7d178f3530699afc31b97a61b014d8e11 /src/resolve/resolved-dns-scope.c
parent9e08a6e0ce6ae37189666fd2517e643e971e45b1 (diff)
resolved: only maintain one question RR key per transaction
Let's simplify things and only maintain a single RR key per transaction object, instead of a full DnsQuestion. Unicast DNS and LLMNR don't support multiple questions per packet anway, and Multicast DNS suggests coalescing questions beyond a single dns query, across the whole system.
Diffstat (limited to 'src/resolve/resolved-dns-scope.c')
-rw-r--r--src/resolve/resolved-dns-scope.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/resolve/resolved-dns-scope.c b/src/resolve/resolved-dns-scope.c
index b1e5855a6f..57a2c7d6c1 100644
--- a/src/resolve/resolved-dns-scope.c
+++ b/src/resolve/resolved-dns-scope.c
@@ -617,11 +617,11 @@ void dns_scope_process_query(DnsScope *s, DnsStream *stream, DnsPacket *p) {
}
}
-DnsTransaction *dns_scope_find_transaction(DnsScope *scope, DnsQuestion *question, bool cache_ok) {
+DnsTransaction *dns_scope_find_transaction(DnsScope *scope, DnsResourceKey *key, bool cache_ok) {
DnsTransaction *t;
assert(scope);
- assert(question);
+ assert(key);
/* Try to find an ongoing transaction that is a equal or a
* superset of the specified question */
@@ -636,7 +636,7 @@ DnsTransaction *dns_scope_find_transaction(DnsScope *scope, DnsQuestion *questio
!t->received)
continue;
- if (dns_question_is_superset(t->question, question) > 0)
+ if (dns_resource_key_equal(t->key, key) > 0)
return t;
}