1
0
mirror of https://github.com/astaxie/beego.git synced 2024-12-23 05:50:51 +00:00

Merge pull request #787 from francoishill/patch-21

Proposal for adding a ":" for stack trace printout
This commit is contained in:
astaxie 2014-08-31 08:52:32 +08:00
commit e6b42a4070

View File

@ -818,8 +818,8 @@ func (p *ControllerRegistor) recoverPanic(rw http.ResponseWriter, r *http.Reques
if !ok {
break
}
Critical(file, line)
stack = stack + fmt.Sprintln(file, line)
Critical(fmt.Sprintf("%s:%d", file, line))
stack = stack + fmt.Sprintln(fmt.Sprintf("%s:%d", file, line))
}
middleware.ShowErr(err, rw, r, stack)
}
@ -840,7 +840,7 @@ func (p *ControllerRegistor) recoverPanic(rw http.ResponseWriter, r *http.Reques
if !ok {
break
}
Critical(file, line)
Critical(fmt.Sprintf("%s:%d", file, line))
}
}
}