Skip to content

Commit

Permalink
Handle Windows platform connection close error
Browse files Browse the repository at this point in the history
Signed-off-by: Austin Vazquez <[email protected]>
  • Loading branch information
austinvazquez committed Mar 1, 2024
1 parent a5aee16 commit 7eb75ab
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions client.go
Original file line number Diff line number Diff line change
Expand Up @@ -392,6 +392,8 @@ func filterCloseErr(err error) error {
return ErrClosed
case strings.Contains(err.Error(), "use of closed network connection"):
return ErrClosed
case strings.Contains(err.Error(), "connection was forcibly closed by the remote host"):
return ErrClosed
default:
// if we have an epipe on a write or econnreset on a read , we cast to errclosed
var oerr *net.OpError
Expand Down

0 comments on commit 7eb75ab

Please sign in to comment.