// isLocalAddress returns whether addr is an address on this machine.
isLocalAddress returns whether addr is an address on this machine.
// isLocalAddress returns whether addr is an address on this machine .
func isLocalAddress(addr net.Addr) bool {
	var host string
	if tcpAddr, ok := addr.(*net.TCPAddr); ok {
		host = tcpAddr.IP.String()
	} else {
		host = addr.String()
	}
	return localAddresses[host]
}
func isLocalAddress ( addr net . Addr ) bool { var host string if tcpAddr , ok := addr . ( * net . TCPAddr ) ; ok { host = tcpAddr . IP . String ( ) } else { host = addr . String ( ) } return localAddresses [ host ] }
isLocalAddress returns whether addr is an address on this machine.
isLocalAddress returns whether addr is an address on this machine .