1
0
mirror of https://github.com/golang/go synced 2024-11-21 21:44:40 -07:00

Deadlock in test if a TLS error occurs

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.
This commit is contained in:
Eric Young 2022-06-03 12:07:57 +10:00
parent 7846e25418
commit 4d84fb8b55

View File

@ -200,7 +200,6 @@ func TestRenegotiationExtension(t *testing.T) {
n, err := c.Read(buf)
if err != nil {
t.Errorf("Server read returned error: %s", err)
return
}
c.Close()
bufChan <- buf[:n]