mirror of
https://github.com/golang/go.git
synced 2025-10-19 11:03:18 +00:00
crypto/tls: fix a testing deadlock that occurs on a TLS protocol error
A Go routine was, on an error, returning without sending a message on its
signaling channel, so the main program was blocking forever waiting for
a message that was never sent. Found while breaking crypto/tls.
Change-Id: Id0b3c070a27cabd852f74e86bb9eff5c66b86d28
GitHub-Last-Rev: 4d84fb8b55
GitHub-Pull-Request: golang/go#53216
Reviewed-on: https://go-review.googlesource.com/c/go/+/410274
Auto-Submit: Sean Liao <sean@liao.dev>
Reviewed-by: Roland Shoemaker <roland@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
Reviewed-by: Sean Liao <sean@liao.dev>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
This commit is contained in:
parent
5715d73559
commit
5ab9d96604
1 changed files with 0 additions and 1 deletions
|
@ -236,7 +236,6 @@ func TestRenegotiationExtension(t *testing.T) {
|
||||||
n, err := c.Read(buf)
|
n, err := c.Read(buf)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
t.Errorf("Server read returned error: %s", err)
|
t.Errorf("Server read returned error: %s", err)
|
||||||
return
|
|
||||||
}
|
}
|
||||||
c.Close()
|
c.Close()
|
||||||
bufChan <- buf[:n]
|
bufChan <- buf[:n]
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue