fix 5022: Miss assiging ln to graceful Server (#5028)

This commit is contained in:
Ming Deng 2022-07-28 22:53:00 +08:00 committed by GitHub
parent 080f4e1a56
commit ab5a13f02a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 3 additions and 0 deletions

View File

@ -3,6 +3,7 @@
- [Fix 4907: make admin serve HTTP only](https://github.com/beego/beego/pull/5005)
- [Feat 4999: add get all tasks function](https://github.com/beego/beego/pull/4999)
- [Fix 5012: fix some bug, pass []any as any in variadic function](https://github.com/beego/beego/pull/5012)
- [Fix 5022: Miss assigning listener to graceful Server](https://github.com/beego/beego/pull/5028)
# v2.0.4

View File

@ -20,6 +20,7 @@ import (
"strings"
"github.com/beego/beego/v2/core/config"
"github.com/pelletier/go-toml"
)
const keySeparator = "."

View File

@ -38,6 +38,7 @@ func (srv *Server) Serve() (err error) {
}
func (srv *Server) ServeWithListener(ln net.Listener) (err error) {
srv.ln = ln
go srv.handleSignals()
return srv.internalServe(ln)
}