diff --git a/service/listeners.go b/service/listeners.go index bbcfb1a4..94f50402 100644 --- a/service/listeners.go +++ b/service/listeners.go @@ -285,7 +285,6 @@ func (m *multiPacketListener) Acquire() (net.PacketConn, error) { m.readCh = make(chan readRequest) m.doneCh = make(chan struct{}) go func() { - defer close(m.readCh) buffer := make([]byte, serverUDPBufferSize) for { n, addr, err := m.pc.ReadFrom(buffer) @@ -301,9 +300,6 @@ func (m *multiPacketListener) Acquire() (net.PacketConn, error) { case <-m.doneCh: return } - if errors.Is(err, net.ErrClosed) { - return - } } }() }