diff options
author | Lennart Poettering <lennart@poettering.net> | 2015-12-18 14:29:32 +0100 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2015-12-18 14:48:49 +0100 |
commit | 1849cb7cb723e8ea7c13b967d056c1d3a36d9042 (patch) | |
tree | d19cae9195c6aaa60b2b33c96d30527a657b62e9 /src | |
parent | 423659abb8e5ff7b43fc458ab0436074f89f03b1 (diff) |
resolved: don't check for NULL DnsAnswer object explicitly where unnecessary
The DNS_ANSWER_FOREACH macros do this internally anyway, no need to
duplicate this.
Diffstat (limited to 'src')
-rw-r--r-- | src/resolve/resolved-dns-answer.c | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/src/resolve/resolved-dns-answer.c b/src/resolve/resolved-dns-answer.c index 5355303bd3..727fa75067 100644 --- a/src/resolve/resolved-dns-answer.c +++ b/src/resolve/resolved-dns-answer.c @@ -233,9 +233,6 @@ int dns_answer_find_soa(DnsAnswer *a, const DnsResourceKey *key, DnsResourceReco assert(key); - if (!a) - return 0; - /* For a SOA record we can never find a matching SOA record */ if (key->type == DNS_TYPE_SOA) return 0; @@ -260,9 +257,6 @@ int dns_answer_find_cname_or_dname(DnsAnswer *a, const DnsResourceKey *key, DnsR assert(key); - if (!a) - return 0; - /* For a {C,D}NAME record we can never find a matching {C,D}NAME record */ if (key->type == DNS_TYPE_CNAME || key->type == DNS_TYPE_DNAME) return 0; |