mirror of
https://github.com/DNSCrypt/dnscrypt-proxy.git
synced 2024-12-29 00:30:30 +01:00
clanup: xtransport: use MaxDNSPacketSize more
This commit is contained in:
parent
0d553a9fa7
commit
72681725b1
@ -158,7 +158,7 @@ func (xTransport *XTransport) resolveUsingResolver(dnsClient *dns.Client, host s
|
||||
if xTransport.useIPv4 {
|
||||
msg := new(dns.Msg)
|
||||
msg.SetQuestion(dns.Fqdn(host), dns.TypeA)
|
||||
msg.SetEdns0(4096, true)
|
||||
msg.SetEdns0(uint16(MaxDNSPacketSize), true)
|
||||
var in *dns.Msg
|
||||
in, _, err = dnsClient.Exchange(msg, resolver)
|
||||
if err == nil {
|
||||
@ -173,7 +173,7 @@ func (xTransport *XTransport) resolveUsingResolver(dnsClient *dns.Client, host s
|
||||
if xTransport.useIPv6 {
|
||||
msg := new(dns.Msg)
|
||||
msg.SetQuestion(dns.Fqdn(host), dns.TypeAAAA)
|
||||
msg.SetEdns0(4096, true)
|
||||
msg.SetEdns0(uint16(MaxDNSPacketSize), true)
|
||||
var in *dns.Msg
|
||||
in, _, err = dnsClient.Exchange(msg, resolver)
|
||||
if err == nil {
|
||||
|
Loading…
Reference in New Issue
Block a user