diff --git a/icslog/icslog.go b/icslog/icslog.go index 36f2fa4..445b4a6 100644 --- a/icslog/icslog.go +++ b/icslog/icslog.go @@ -130,7 +130,8 @@ func NewIcsLog(conf *icsconf.LogConfig, level int, output int, path string, disk //make log file - icsvg.log-yyyymmdd yyyy, mm, dd := gIcsLog.CurrentDate.Date() - gIcsLog.LogFileName = fmt.Sprintf("%s/icsvs.log-%d%02d%02d", gIcsLog.Path, yyyy, mm, dd) + hh, mi := time.Now().Hour(), time.Now().Minute() + gIcsLog.LogFileName = fmt.Sprintf("%s/icsvs.log-%d%02d%02d.%02d.%02d", gIcsLog.Path, yyyy, mm, dd, hh, mi) stat, err := os.Stat(gIcsLog.LogFileName) if err == nil {