mirror of https://github.com/fluffle/goirc
Actually perform SSL handshake when we claim to. Fixes #89.
This commit is contained in:
parent
20e4ea9b00
commit
a2223065b2
|
@ -341,7 +341,11 @@ func (conn *Conn) Connect() error {
|
||||||
|
|
||||||
if conn.cfg.SSL {
|
if conn.cfg.SSL {
|
||||||
logging.Info("irc.Connect(): Performing SSL handshake.")
|
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)
|
conn.postConnect(true)
|
||||||
|
|
Loading…
Reference in New Issue