This commit is contained in:
astaxie 2014-08-01 17:03:28 +08:00
parent 7a39a3c52f
commit 0836b9e13f
1 changed files with 2 additions and 0 deletions

2
app.go
View File

@ -69,6 +69,7 @@ func (app *App) Run() {
if EnableHttpTLS {
go func() {
time.Sleep(20 * time.Microsecond)
if HttpsPort != 0 {
app.Server.Addr = fmt.Sprintf("%s:%d", HttpAddr, HttpsPort)
}
@ -83,6 +84,7 @@ func (app *App) Run() {
if EnableHttpListen {
go func() {
app.Server.Addr = addr
err := app.Server.ListenAndServe()
if err != nil {
BeeLogger.Critical("ListenAndServe: ", err)