mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-19 02:12:23 +00:00
log: automatically add 2 (skipLevel) to the step in log.Output
This commit is contained in:
parent
c7799560cf
commit
d8b75b445a
1 changed files with 3 additions and 2 deletions
|
|
@ -60,7 +60,8 @@ func Crit(msg string, ctx ...interface{}) {
|
|||
os.Exit(1)
|
||||
}
|
||||
|
||||
// Output is a convenient alias for write
|
||||
// Output is a convenient alias for write, allowing for the modification of
|
||||
// the skip step (number of stack frames to skip)
|
||||
func Output(msg string, lvl Lvl, skip int, ctx ...interface{}) {
|
||||
root.write(msg, lvl, ctx, skip)
|
||||
root.write(msg, lvl, ctx, skip+skipLevel)
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue