diff --git a/gin.go b/gin.go index 847df19c..4d163d5f 100644 --- a/gin.go +++ b/gin.go @@ -129,7 +129,9 @@ func (engine *Engine) ServeHTTP(w http.ResponseWriter, req *http.Request) { } func (engine *Engine) Run(addr string) { - http.ListenAndServe(addr, engine) + if err := http.ListenAndServe(addr, engine); err != nil { + panic(err) + } } /************************************/