fix panic
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
This commit is contained in:
parent
41bf69e97c
commit
62e40d4119
4
http.go
4
http.go
@ -252,6 +252,10 @@ func (h *httpServer) Start() error {
|
|||||||
hd := h.hd
|
hd := h.hd
|
||||||
h.RUnlock()
|
h.RUnlock()
|
||||||
|
|
||||||
|
if hd == nil {
|
||||||
|
return errors.New("Server required http.Handler")
|
||||||
|
}
|
||||||
|
|
||||||
ln, err := net.Listen("tcp", config.Address)
|
ln, err := net.Listen("tcp", config.Address)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
|
Loading…
Reference in New Issue
Block a user