summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--main.go6
1 files changed, 5 insertions, 1 deletions
diff --git a/main.go b/main.go
index 59295d1..8cef1ac 100644
--- a/main.go
+++ b/main.go
@@ -1,6 +1,7 @@
package main
import (
+ "crypto/tls"
"flag"
"fmt"
"log"
@@ -107,7 +108,10 @@ func main() {
conf := irc.NewConfig(*name)
conf.Server = *node
- conf.SSL = !*notls
+ if !*notls {
+ conf.SSL = true
+ conf.SSLConfig = &tls.Config{ServerName: *node}
+ }
conn := irc.Client(conf)
done := make(chan struct{})