summaryrefslogtreecommitdiff
path: root/src/resolve/resolved-dns-scope.c
diff options
context:
space:
mode:
authorTom Gundersen <teg@jklm.no>2015-11-19 02:22:12 +0100
committerTom Gundersen <teg@jklm.no>2015-11-19 02:22:12 +0100
commit854c1123f5fb6704e900d34c0165360f77ce4ef8 (patch)
treefce7df637e3e88fe5ce837a15f22d99e2e8d0adb /src/resolve/resolved-dns-scope.c
parent25422154e8ebda7a9bfd52d7e0cbd7254fed39b3 (diff)
parent39609489ca9925f94fdd4ef12a8b3d5ee2e14ddd (diff)
Merge pull request #1944 from poettering/randoms-ec
add RandomSec= setting to timer units, and more
Diffstat (limited to 'src/resolve/resolved-dns-scope.c')
-rw-r--r--src/resolve/resolved-dns-scope.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/resolve/resolved-dns-scope.c b/src/resolve/resolved-dns-scope.c
index b15370b017..873d76e40c 100644
--- a/src/resolve/resolved-dns-scope.c
+++ b/src/resolve/resolved-dns-scope.c
@@ -543,6 +543,7 @@ static void dns_scope_verify_conflicts(DnsScope *s, DnsPacket *p) {
void dns_scope_process_query(DnsScope *s, DnsStream *stream, DnsPacket *p) {
_cleanup_(dns_packet_unrefp) DnsPacket *reply = NULL;
_cleanup_(dns_answer_unrefp) DnsAnswer *answer = NULL, *soa = NULL;
+ DnsResourceKey *key = NULL;
bool tentative = false;
int r, fd;
@@ -576,7 +577,10 @@ void dns_scope_process_query(DnsScope *s, DnsStream *stream, DnsPacket *p) {
return;
}
- r = dns_zone_lookup(&s->zone, p->question, &answer, &soa, &tentative);
+ assert(p->question->n_keys == 1);
+ key = p->question->keys[0];
+
+ r = dns_zone_lookup(&s->zone, key, &answer, &soa, &tentative);
if (r < 0) {
log_debug_errno(r, "Failed to lookup key: %m");
return;