Skip to content

Commit

Permalink
Filters out CR (\r) characters from log messages
Browse files Browse the repository at this point in the history
  • Loading branch information
gdavison committed Mar 9, 2022
1 parent 26f9d4d commit 8327692
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion logger.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,7 @@ func (l DebugLogger) Log(args ...interface{}) {
tokens = append(tokens, token)
}
}
log.Printf("[DEBUG] [aws-sdk-go] %s", strings.Join(tokens, " "))
s := strings.Join(tokens, " ")
s = strings.ReplaceAll(s, "\r", "") // Works around https://github.com/jen20/teamcity-go-test/pull/2
log.Printf("[DEBUG] [aws-sdk-go] %s", s)
}

0 comments on commit 8327692

Please sign in to comment.