summaryrefslogtreecommitdiff
path: root/src/resolve/resolved-dns-query.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2014-07-16 03:28:18 +0200
committerLennart Poettering <lennart@poettering.net>2014-07-16 03:28:18 +0200
commitb9d394ea565fd742bcdd34e8dd61ae07c58a9565 (patch)
tree29ca3c5d2f4fb27ee3bd70106e77db146b9d25e8 /src/resolve/resolved-dns-query.c
parent9d6db739ce1eaa3eace21801fd606d523b73c8f4 (diff)
resolve: add distinct bus error code for hosts that exist but lack A or AAAA records
Diffstat (limited to 'src/resolve/resolved-dns-query.c')
-rw-r--r--src/resolve/resolved-dns-query.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/src/resolve/resolved-dns-query.c b/src/resolve/resolved-dns-query.c
index a9880524e6..dd812150cf 100644
--- a/src/resolve/resolved-dns-query.c
+++ b/src/resolve/resolved-dns-query.c
@@ -107,12 +107,9 @@ int dns_query_transaction_reply(DnsQueryTransaction *t, DnsPacket *p) {
t->packet = dns_packet_ref(p);
- if (DNS_PACKET_RCODE(p) == DNS_RCODE_SUCCESS) {
- if( be16toh(DNS_PACKET_HEADER(p)->ancount) > 0)
- dns_query_transaction_set_state(t, DNS_QUERY_SUCCESS);
- else
- dns_query_transaction_set_state(t, DNS_QUERY_INVALID_REPLY);
- } else
+ if (DNS_PACKET_RCODE(p) == DNS_RCODE_SUCCESS)
+ dns_query_transaction_set_state(t, DNS_QUERY_SUCCESS);
+ else
dns_query_transaction_set_state(t, DNS_QUERY_FAILURE);
return 0;