TUN-8461: Don't log Failed to send session payload if the error is EOF
This commit is contained in:
parent
a16532dbbb
commit
cb6e5999e1
|
@ -57,7 +57,7 @@ func (s *Session) Serve(ctx context.Context, closeAfterIdle time.Duration) (clos
|
||||||
readBuffer := make([]byte, maxPacketSize)
|
readBuffer := make([]byte, maxPacketSize)
|
||||||
for {
|
for {
|
||||||
if closeSession, err := s.dstToTransport(readBuffer); err != nil {
|
if closeSession, err := s.dstToTransport(readBuffer); err != nil {
|
||||||
if errors.Is(err, net.ErrClosed) {
|
if errors.Is(err, net.ErrClosed) || errors.Is(err, io.EOF) {
|
||||||
s.log.Debug().Msg("Destination connection closed")
|
s.log.Debug().Msg("Destination connection closed")
|
||||||
} else {
|
} else {
|
||||||
level := zerolog.ErrorLevel
|
level := zerolog.ErrorLevel
|
||||||
|
|
Loading…
Reference in New Issue