From 304beaf89ffe65e2f4a6d4a19ec80d5303f24f04 Mon Sep 17 00:00:00 2001 From: astaxie Date: Mon, 3 Nov 2014 16:40:08 +0800 Subject: [PATCH] update the log call deep --- logs/log.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/logs/log.go b/logs/log.go index d24e21d2..341df572 100644 --- a/logs/log.go +++ b/logs/log.go @@ -154,7 +154,7 @@ func (bl *BeeLogger) writerMsg(loglevel int, msg string) error { lm := new(logMsg) lm.level = loglevel if bl.enableFuncCallDepth { - _, file, line, ok := runtime.Caller(bl.loggerFuncCallDepth + 1) + _, file, line, ok := runtime.Caller(bl.loggerFuncCallDepth) if ok { _, filename := path.Split(file) lm.msg = fmt.Sprintf("[%s:%d] %s", filename, line, msg)