Skip to content

crypto/tls: Conn.WaitConnectionState unrealiable? #657

Description

@gopherbot

by matthew.dempsky:

There's no documentation on what crypto.tls.Conn.WaitConnectionState is 
actually supposed to do, so maybe this is intentional, but looking at the code, 
it appears that if the handshake has already been made by time the caller 
calls WaitConnectionState, then he will get an immediate ConnectionState 
response, and then the channel will still get queued.

I would think the channel should only get added to waitQueue if the 
handshake has not already been made, so that the record processor does not 
try to write to the channel again later.

http://golang.org/src/pkg/crypto/tls/record_process.go#L134

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions