From 1a2e267dae50dde383954a6093398b0a3f617517 Mon Sep 17 00:00:00 2001 From: mreiger Date: Thu, 22 Apr 2021 13:34:27 +0200 Subject: [PATCH] Added missing return statement so we don't try to use a non-existing connection --- pkg/konnectivityproxy/konnectivityproxy.go | 1 + 1 file changed, 1 insertion(+) diff --git a/pkg/konnectivityproxy/konnectivityproxy.go b/pkg/konnectivityproxy/konnectivityproxy.go index dc002f7..cb40b78 100644 --- a/pkg/konnectivityproxy/konnectivityproxy.go +++ b/pkg/konnectivityproxy/konnectivityproxy.go @@ -53,6 +53,7 @@ func (p *Proxy) forward() { srvConn, err := p.listener.AcceptTCP() if err != nil { p.logger.Errorw("Error accepting connection on listener", "listener:", p.listener) + return } p.logger.Infow("New connection", "listener", p.listener, "to (listener address)", srvConn.LocalAddr(), "from (client address)", srvConn.RemoteAddr())