From: Adam Langley Date: Tue, 15 Feb 2011 21:38:45 +0000 (-0500) Subject: crypto/tls: make protocol negotiation failure fatal X-Git-Tag: weekly.2011-02-24~103 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=a0c3b96065e6291cab072eb526ac4c49c6d06aa3;p=gostls13.git crypto/tls: make protocol negotiation failure fatal R=r, r2 CC=golang-dev https://golang.org/cl/4178054 --- diff --git a/src/pkg/crypto/tls/handshake_client.go b/src/pkg/crypto/tls/handshake_client.go index 19d2bfa3ba..a325a9b953 100644 --- a/src/pkg/crypto/tls/handshake_client.go +++ b/src/pkg/crypto/tls/handshake_client.go @@ -57,7 +57,7 @@ func (c *Conn) clientHandshake() os.Error { vers, ok := mutualVersion(serverHello.vers) if !ok { - c.sendAlert(alertProtocolVersion) + return c.sendAlert(alertProtocolVersion) } c.vers = vers c.haveVers = true