crypto/tls: don't return an error from Close()
Fixes #1037. R=adg, rsc1 CC=golang-dev https://golang.org/cl/2107048
This commit is contained in:
parent
99e338e9ec
commit
4c5892dcab
6
conn.go
6
conn.go
@ -445,7 +445,11 @@ func (c *Conn) sendAlertLocked(err alert) os.Error {
|
||||
}
|
||||
c.tmp[1] = byte(err)
|
||||
c.writeRecord(recordTypeAlert, c.tmp[0:2])
|
||||
return c.setError(&net.OpError{Op: "local error", Error: err})
|
||||
// closeNotify is a special case in that it isn't an error:
|
||||
if err != alertCloseNotify {
|
||||
return c.setError(&net.OpError{Op: "local error", Error: err})
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// sendAlert sends a TLS alert message.
|
||||
|
Loading…
Reference in New Issue
Block a user