diff --git a/command/agent/dns.go b/command/agent/dns.go index 0a0f23e6dc..2a8d8dd5c3 100644 --- a/command/agent/dns.go +++ b/command/agent/dns.go @@ -509,7 +509,7 @@ func trimUDPAnswers(config *DNSConfig, resp *dns.Msg) (trimmed bool) { resp.Answer = resp.Answer[:len(resp.Answer)-1] } - return len(resp.Answer) < maxAnswers + return len(resp.Answer) < numAnswers } // serviceLookup is used to handle a service query