when i use ipv6 to run my code
error message output:
listen tcp [fe80::216:3eff:fe2c:e43e]:19090: bind: invalid argument
and then i read echo source code find server listen created by default way:
func newListener(address string) (*tcpKeepAliveListener, error) {
l, err := net.Listen("tcp", address)
if err != nil {
return nil, err
}
return &tcpKeepAliveListener{l.(*net.TCPListener)}, nil
}
tcp may be only bind address by tcp4
when i use ipv6 to run my code
error message output:
and then i read echo source code find server listen created by default way:
tcp may be only bind address by tcp4