MCPcopy
hub / github.com/moby/moby / Run

Method Run

cmd/docker-proxy/sctp_proxy_linux.go:67–78  ·  view source on GitHub ↗

Run starts forwarding the traffic using SCTP.

()

Source from the content-addressed store, hash-verified

65
66// Run starts forwarding the traffic using SCTP.
67func (proxy *SCTPProxy) Run() {
68 quit := make(chan bool)
69 defer close(quit)
70 for {
71 client, err := proxy.listener.Accept()
72 if err != nil {
73 log.Printf("Stopping proxy on sctp/%v for sctp/%v (%s)", proxy.frontendAddr, proxy.backendAddr, err)
74 return
75 }
76 go proxy.clientLoop(client.(*sctp.SCTPConn), quit)
77 }
78}
79
80// Close stops forwarding the traffic.
81func (proxy *SCTPProxy) Close() { proxy.listener.Close() }

Callers

nothing calls this directly

Calls 1

clientLoopMethod · 0.95

Tested by

no test coverage detected