You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

trace.go 396B

12345678910111213141516171819
  1. // +build go1.8
  2. package websocket
  3. import (
  4. "crypto/tls"
  5. "net/http/httptrace"
  6. )
  7. func doHandshakeWithTrace(trace *httptrace.ClientTrace, tlsConn *tls.Conn, cfg *tls.Config) error {
  8. if trace.TLSHandshakeStart != nil {
  9. trace.TLSHandshakeStart()
  10. }
  11. err := doHandshake(tlsConn, cfg)
  12. if trace.TLSHandshakeDone != nil {
  13. trace.TLSHandshakeDone(tlsConn.ConnectionState(), err)
  14. }
  15. return err
  16. }