Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
donnie4w committed Aug 27, 2017
1 parent d18a50f commit 4740c51
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions logger/logw.go
Original file line number Diff line number Diff line change
Expand Up @@ -345,6 +345,8 @@ func (this *fileBean) rename(rolltype _ROLLTYPE) {
os.Remove(nextfilename)
}
os.Rename(this.dir+"/"+this.filename, nextfilename)
t, _ := time.Parse(_DATEFORMAT, time.Now().Format(_DATEFORMAT))
this._date = &t
this.logfile, _ = os.OpenFile(this.dir+"/"+this.filename, os.O_RDWR|os.O_APPEND|os.O_CREATE, 0666)
this.lg = log.New(this.logfile, "", log.Ldate|log.Ltime|log.Lshortfile)
this.filesize = fileSize(this.dir + "/" + this.filename)
Expand Down

0 comments on commit 4740c51

Please sign in to comment.