Skip to content

Commit

Permalink
fix:gz files are compressed repeatedly every time tick (#3236)
Browse files Browse the repository at this point in the history
  • Loading branch information
cyruslo authored Jan 2, 2024
1 parent 63bdf41 commit 4876ae0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion os/glog/glog_logger_rotate.go
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ func (l *Logger) rotateChecksTimely(ctx context.Context) {
)
for _, file := range files {
// ignore backup file
if gregex.IsMatchString(`.+\.\d{20}\.log`, gfile.Basename(file)) {
if gregex.IsMatchString(`.+\.\d{20}\.log`, gfile.Basename(file)) || gfile.ExtName(file) == "gz" {
continue
}
// ignore not matching file
Expand Down

0 comments on commit 4876ae0

Please # to comment.