- install: fix crash when trying to use uninitialized TLS module

This commit is contained in:
Simon Zolin 2020-04-07 19:24:29 +03:00
parent 105e2dd1ee
commit 6690441240

View File

@ -566,7 +566,9 @@ func printHTTPAddresses(proto string) {
var address string
tlsConf := tlsConfigSettings{}
Context.tls.WriteDiskConfig(&tlsConf)
if Context.tls != nil {
Context.tls.WriteDiskConfig(&tlsConf)
}
if proto == "https" && tlsConf.ServerName != "" {
if tlsConf.PortHTTPS == 443 {
log.Printf("Go to https://%s", tlsConf.ServerName)