Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix little nit for klog #238

Merged
merged 1 commit into from
May 12, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions klog.go
Original file line number Diff line number Diff line change
Expand Up @@ -284,6 +284,7 @@ func (m *moduleSpec) Get() interface{} {

var errVmoduleSyntax = errors.New("syntax error: expect comma-separated list of filename=N")

// Set will sets module value
// Syntax: -vmodule=recordio=2,file=1,gfs*=3
func (m *moduleSpec) Set(value string) error {
var filter []modulePat
Expand Down Expand Up @@ -362,6 +363,7 @@ func (t *traceLocation) Get() interface{} {

var errTraceSyntax = errors.New("syntax error: expect file.go:234")

// Set will sets backtrace value
// Syntax: -log_backtrace_at=gopherflakes.go:234
// Note that unlike vmodule the file extension is included here.
func (t *traceLocation) Set(value string) error {
Expand Down
2 changes: 1 addition & 1 deletion klog_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -647,7 +647,7 @@ func BenchmarkLogs(b *testing.B) {

testFile, err := ioutil.TempFile("", "test.log")
if err != nil {
b.Error("unable to create temporary file")
b.Fatal("unable to create temporary file")
}
defer os.Remove(testFile.Name())

Expand Down
2 changes: 1 addition & 1 deletion klogr/klogr.go
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ func framesToCaller() int {
return 1 // something went wrong, this is safe
}

// trimDuplicates will deduplicates elements provided in multiple KV tuple
// trimDuplicates will deduplicate elements provided in multiple KV tuple
// slices, whilst maintaining the distinction between where the items are
// contained.
func trimDuplicates(kvLists ...[]interface{}) [][]interface{} {
Expand Down