Skip to content

Commit

Permalink
append instead of trunc
Browse files Browse the repository at this point in the history
  • Loading branch information
absolutelightning committed Aug 31, 2023
1 parent 4874f5a commit 898bd1e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion logging/logfile.go
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ func (l *LogFile) openNew() error {
newfilePath := filepath.Join(l.logPath, newfileName)

// Try creating a file. We truncate the file because we are the only authority to write the logs
filePointer, err := os.OpenFile(newfilePath, os.O_CREATE|os.O_TRUNC|os.O_WRONLY, 0640)
filePointer, err := os.OpenFile(newfilePath, os.O_CREATE|os.O_APPEND|os.O_WRONLY, 0640)
if err != nil {
return err
}
Expand Down

0 comments on commit 898bd1e

Please sign in to comment.