Lines Matching refs:network
31 func newLocalListener(network string) (Listener, error) {
32 switch network {
51 return Listen(network, testUnixAddr())
53 return nil, fmt.Errorf("%s is not supported", network)
58 network string
69 ln, err := ListenTCP(arg.network, &arg.TCPAddr)
104 network := ls.Listener.Addr().Network()
109 switch network {
118 func newLocalServer(network string) (*localServer, error) {
119 ln, err := newLocalListener(network)
127 network, address string
155 func (dss *dualStackServer) teardownNetwork(network string) error {
158 if network == dss.lns[i].network && dss.lns[i].Listener != nil {
200 {network: "tcp4", address: lns[0].Addr().String(), Listener: lns[0], done: make(chan bool)},
201 {network: "tcp6", address: lns[1].Addr().String(), Listener: lns[1], done: make(chan bool)},
226 network := ln.Addr().Network()
227 if c.LocalAddr().Network() != network || c.RemoteAddr().Network() != network {
228 ch <- fmt.Errorf("got %v->%v; expected %v->%v", c.LocalAddr().Network(), c.RemoteAddr().Network(), network, network)
333 func newLocalPacketListener(network string) (PacketConn, error) {
334 switch network {
351 return ListenPacket(network, testUnixAddr())
353 return nil, fmt.Errorf("%s is not supported", network)
358 network string
369 c, err := ListenUDP(arg.network, &arg.UDPAddr)
404 network := ls.PacketConn.LocalAddr().Network()
409 switch network {
418 func newLocalPacketServer(network string) (*localPacketServer, error) {
419 c, err := newLocalPacketListener(network)
451 switch c.LocalAddr().Network() {