Skip to content

Commit c274774

Browse files
committed
tidy
1 parent fdcbf6b commit c274774

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

std/crypto/tls/conn.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -758,7 +758,8 @@ func (c *Conn) readRecordOrCCS(expectChangeCipherSpec bool) error {
758758
if err == io.ErrUnexpectedEOF && (c.rawInput == nil || (len(*c.rawInput)-c.rawInputOff == 0)) {
759759
err = io.EOF
760760
}
761-
if e, ok := err.(net.Error); !ok || !e.Temporary() {
761+
var ne net.Error
762+
if ok := errors.As(err, &ne); !ok || !ne.Timeout() {
762763
c.in.setErrorLocked(err)
763764
}
764765
return err

0 commit comments

Comments
 (0)