mirror of
https://github.com/golang/go
synced 2024-11-23 00:50:05 -07:00
doc/go1.16: document net.ErrClosed usage in crypto/tls
Change-Id: I130cf79b93c6456dbe87f0042209e204c4e319b2 Reviewed-on: https://go-review.googlesource.com/c/go/+/257457 Reviewed-by: Ian Lance Taylor <iant@golang.org> Reviewed-by: Emmanuel Odeke <emm.odeke@gmail.com> Trust: Emmanuel Odeke <emm.odeke@gmail.com>
This commit is contained in:
parent
7bb6fed9b5
commit
72a9dec156
@ -164,6 +164,16 @@ Do not send CLs removing the interior tags from such phrases.
|
||||
TODO
|
||||
</p>
|
||||
|
||||
<h3 id="ctypto/tls"><a href="/pkg/crypto/tls">crypto/tls</a></h3>
|
||||
|
||||
<p><!-- CL 256897 -->
|
||||
I/O operations on closing or closed TLS connections can now be detected using
|
||||
the new <a href="/pkg/net/#ErrClosed">ErrClosed</a> error. A typical use
|
||||
would be <code>errors.Is(err, net.ErrClosed)</code>. In earlier releases
|
||||
the only way to reliably detect this case was to match the string returned
|
||||
by the <code>Error</code> method with <code>"tls: use of closed connection"</code>.
|
||||
</p>
|
||||
|
||||
<h3 id="net"><a href="/pkg/net/">net</a></h3>
|
||||
|
||||
<p><!-- CL 250357 -->
|
||||
|
Loading…
Reference in New Issue
Block a user