mirror of
https://github.com/labstack/echo.git
synced 2025-01-12 01:22:21 +02:00
Fixed null pointer on standard engine
Signed-off-by: Vishal Rana <vr@labstack.com>
This commit is contained in:
parent
79f7be2e21
commit
86ddfedb45
@ -42,10 +42,7 @@ func NewWithTLS(addr, certfile, keyfile string) *Server {
|
||||
|
||||
func NewWithConfig(c *engine.Config) (s *Server) {
|
||||
s = &Server{
|
||||
server: &http.Server{
|
||||
Addr: c.Address,
|
||||
Handler: s,
|
||||
},
|
||||
server: new(http.Server),
|
||||
config: c,
|
||||
pool: &Pool{
|
||||
request: sync.Pool{
|
||||
@ -74,6 +71,8 @@ func NewWithConfig(c *engine.Config) (s *Server) {
|
||||
}),
|
||||
logger: log.New("echo"),
|
||||
}
|
||||
s.server.Addr = c.Address
|
||||
s.server.Handler = s
|
||||
return
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user