]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
resolve: dns_scope_network_good() does not returns negative errno
authorYu Watanabe <watanabe.yu+github@gmail.com>
Mon, 25 Jun 2018 04:20:35 +0000 (13:20 +0900)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Mon, 25 Jun 2018 04:25:34 +0000 (13:25 +0900)
src/resolve/resolved-dns-transaction.c

index c60b8215a6ff01eeac1b92124b2b0ea3ac0c9f77..5805546cf374b7977d6c4b272647f6aac469fbdb 100644 (file)
@@ -1380,10 +1380,7 @@ static int dns_transaction_prepare(DnsTransaction *t, usec_t ts) {
 
         dns_transaction_stop_timeout(t);
 
-        r = dns_scope_network_good(t->scope);
-        if (r < 0)
-                return r;
-        if (r == 0) {
+        if (!dns_scope_network_good(t->scope)) {
                 dns_transaction_complete(t, DNS_TRANSACTION_NETWORK_DOWN);
                 return 0;
         }