cmd/docker-proxy: format code with gofumpt

Formatting the code with https://github.com/mvdan/gofumpt

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
Sebastiaan van Stijn 2022-01-20 13:50:08 +01:00
parent 0af6d9e291
commit 47276bdb28
No known key found for this signature in database
GPG key ID: 76698F39D527CE8C
3 changed files with 6 additions and 4 deletions

View file

@ -14,8 +14,10 @@ import (
"gotest.tools/v3/skip"
)
var testBuf = []byte("Buffalo buffalo Buffalo buffalo buffalo buffalo Buffalo buffalo")
var testBufSize = len(testBuf)
var (
testBuf = []byte("Buffalo buffalo Buffalo buffalo buffalo buffalo Buffalo buffalo")
testBufSize = len(testBuf)
)
type EchoServer interface {
Run()

View file

@ -48,7 +48,7 @@ func (proxy *SCTPProxy) clientLoop(client *sctp.SCTPConn, quit chan bool) {
backendC := sctp.NewSCTPSndRcvInfoWrappedConn(backend)
var wg sync.WaitGroup
var broker = func(to, from net.Conn) {
broker := func(to, from net.Conn) {
io.Copy(to, from)
from.Close()
to.Close()

View file

@ -44,7 +44,7 @@ func (proxy *TCPProxy) clientLoop(client *net.TCPConn, quit chan bool) {
}
var wg sync.WaitGroup
var broker = func(to, from *net.TCPConn) {
broker := func(to, from *net.TCPConn) {
io.Copy(to, from)
from.CloseRead()
to.CloseWrite()