Browse Source

Fix: fix failure of cache expired DNS record querying over DoH (#1706)

KujouRinka 3 years ago
parent
commit
2dc4ee2d51
1 changed files with 2 additions and 2 deletions
  1. 2 2
      app/dns/nameserver_doh.go

+ 2 - 2
app/dns/nameserver_doh.go

@@ -297,7 +297,7 @@ func (s *DoHNameServer) findIPsForDomain(domain string, option dns_feature.IPOpt
 
 	var ips []net.Address
 	var lastErr error
-	if option.IPv6Enable && record.AAAA != nil && record.AAAA.RCode == dnsmessage.RCodeSuccess {
+	if option.IPv6Enable {
 		aaaa, err := record.AAAA.getIPs()
 		if err != nil {
 			lastErr = err
@@ -305,7 +305,7 @@ func (s *DoHNameServer) findIPsForDomain(domain string, option dns_feature.IPOpt
 		ips = append(ips, aaaa...)
 	}
 
-	if option.IPv4Enable && record.A != nil && record.A.RCode == dnsmessage.RCodeSuccess {
+	if option.IPv4Enable {
 		a, err := record.A.getIPs()
 		if err != nil {
 			lastErr = err