websocket icon indicating copy to clipboard operation
websocket copied to clipboard

Use net.ErrClosed

Open emersion opened this issue 3 years ago • 1 comments

Go 1.16 has introduced net.ErrClosed, which should be returned/wrapped when an I/O call is performed on a network connection which has already been closed. This is useful to avoid cluttering logs with messages like failed to close WebSocket: already wrote close.

emersion avatar Mar 10 '21 08:03 emersion

Will do, thanks for reporting!

nhooyr avatar Apr 07 '21 15:04 nhooyr

Done in #303

nhooyr avatar Oct 13 '23 07:10 nhooyr