summaryrefslogtreecommitdiff
path: root/src/resolve/resolved-dns-query.c
diff options
context:
space:
mode:
authorYu Watanabe <watanabe.yu+github@gmail.com>2022-02-23 07:50:30 +0900
committerYu Watanabe <watanabe.yu+github@gmail.com>2022-02-23 07:53:57 +0900
commit176a9a2cca47f7c1553d96f7dd51c2193a269dbc (patch)
tree33b41a5d7f34501fbab785ee11b31461f45c2056 /src/resolve/resolved-dns-query.c
parent830f50ab1e03fa7ee262876ed42023d10e89688d (diff)
downloadsystemd-176a9a2cca47f7c1553d96f7dd51c2193a269dbc.tar.gz
resolve: make dns_scope_good_domain() take DnsQuery*
Diffstat (limited to 'src/resolve/resolved-dns-query.c')
-rw-r--r--src/resolve/resolved-dns-query.c14
1 files changed, 2 insertions, 12 deletions
diff --git a/src/resolve/resolved-dns-query.c b/src/resolve/resolved-dns-query.c
index 7dc346794e..c0bb40937a 100644
--- a/src/resolve/resolved-dns-query.c
+++ b/src/resolve/resolved-dns-query.c
@@ -737,13 +737,8 @@ int dns_query_go(DnsQuery *q) {
LIST_FOREACH(scopes, s, q->manager->dns_scopes) {
DnsScopeMatch match;
- const char *name;
- name = dns_question_first_name(dns_query_question_for_protocol(q, s->protocol));
- if (!name)
- continue;
-
- match = dns_scope_good_domain(s, q->ifindex, q->flags, name);
+ match = dns_scope_good_domain(s, q);
assert(match >= 0);
if (match > found) { /* Does this match better? If so, remember how well it matched, and the first one
* that matches this well */
@@ -769,13 +764,8 @@ int dns_query_go(DnsQuery *q) {
LIST_FOREACH(scopes, s, first->scopes_next) {
DnsScopeMatch match;
- const char *name;
-
- name = dns_question_first_name(dns_query_question_for_protocol(q, s->protocol));
- if (!name)
- continue;
- match = dns_scope_good_domain(s, q->ifindex, q->flags, name);
+ match = dns_scope_good_domain(s, q);
assert(match >= 0);
if (match < found)
continue;