Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 1 of 1 for CanonicalAddr (0.1 sec)

  1. src/net/http/transport.go

    func idnaASCIIFromURL(url *url.URL) string {
    	addr := url.Hostname()
    	if v, err := idnaASCII(addr); err == nil {
    		addr = v
    	}
    	return addr
    }
    
    // canonicalAddr returns url.Host but always with a ":port" suffix.
    func canonicalAddr(url *url.URL) string {
    	port := url.Port()
    	if port == "" {
    		port = portMap[url.Scheme]
    	}
    	return net.JoinHostPort(idnaASCIIFromURL(url), port)
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Jun 06 21:59:21 UTC 2024
    - 91K bytes
    - Viewed (0)
Back to top