mirror of
https://github.com/DNSCrypt/dnscrypt-proxy.git
synced 2025-03-04 02:14:40 +01:00
Rename resolveHost() to resolveHostWithCache() for clarity
(but to be honest, I don't understand anything to that code any more)
This commit is contained in:
parent
e028f4d483
commit
3cef651b07
1 changed files with 2 additions and 2 deletions
|
@ -242,7 +242,7 @@ func (xTransport *XTransport) resolveUsingResolver(proto, host string, resolver
|
|||
return
|
||||
}
|
||||
|
||||
func (xTransport *XTransport) resolveHost(host string) (err error) {
|
||||
func (xTransport *XTransport) resolveHostWithCache(host string) (err error) {
|
||||
if xTransport.proxyDialer != nil || xTransport.httpProxyFunction != nil {
|
||||
return
|
||||
}
|
||||
|
@ -314,7 +314,7 @@ func (xTransport *XTransport) Fetch(method string, url *url.URL, accept string,
|
|||
if xTransport.proxyDialer == nil && strings.HasSuffix(host, ".onion") {
|
||||
return nil, 0, errors.New("Onion service is not reachable without Tor")
|
||||
}
|
||||
if err := xTransport.resolveHost(host); err != nil {
|
||||
if err := xTransport.resolveHostWithCache(host); err != nil {
|
||||
return nil, 0, err
|
||||
}
|
||||
req := &http.Request{
|
||||
|
|
Loading…
Add table
Reference in a new issue