This commit is contained in:
Xavier Henner 2019-08-17 11:33:14 +02:00
parent 6dd6211f79
commit 0b7ea3240d
2 changed files with 3 additions and 3 deletions

View File

@ -130,8 +130,8 @@ func NewHTTPServer(port, key, cert string, s *OpenVpnMgt) {
switch { switch {
case key == "" && cert == "": case key == "" && cert == "":
log.Fatal(http.ListenAndServeTLS(port, cert, key, nil))
default:
log.Fatal(http.ListenAndServe(port, nil)) log.Fatal(http.ListenAndServe(port, nil))
default:
log.Fatal(http.ListenAndServeTLS(port, cert, key, nil))
} }
} }

View File

@ -22,7 +22,7 @@ func main() {
// parseconfig // parseconfig
if config, err = uconfig.New(*configFile); err != nil { if config, err = uconfig.New(*configFile); err != nil {
log.Println(err) log.Println("config", configFile, err)
os.Exit(1) os.Exit(1)
} }