1
0
Fork 0
mirror of https://github.com/fluffle/goirc synced 2025-05-13 02:53:19 +00:00

Actually perform SSL handshake when we claim to. Fixes #89.

This commit is contained in:
Alex Bramley 2016-08-24 08:28:48 +01:00
parent 20e4ea9b00
commit a2223065b2

View file

@ -341,7 +341,11 @@ func (conn *Conn) Connect() error {
if conn.cfg.SSL {
logging.Info("irc.Connect(): Performing SSL handshake.")
conn.sock = tls.Client(conn.sock, conn.cfg.SSLConfig)
s := tls.Client(conn.sock, conn.cfg.SSLConfig)
if err := s.Handshake(); err != nil {
return err
}
conn.sock = s
}
conn.postConnect(true)