Skip to content

Commit 6519e29

Browse files
author
suhuaqin
committed
fix: use defaultCPUSamplingTime
1 parent 41be02e commit 6519e29

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

options.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -238,14 +238,14 @@ func WithCPUMax(max int) Option {
238238
func WithCPUSamplingTime(duration string) Option {
239239
return optionFunc(func(opts *options) (err error) {
240240
// CPUSamplingTime wouldn't be zero value, because it
241-
// will be initialized as defaultInterval at newOptions()
241+
// will be initialized as defaultCPUSamplingTime at newOptions()
242242
newDuration, err := time.ParseDuration(duration)
243243
if err != nil {
244244
return
245245
}
246246

247247
if newDuration <= 0 {
248-
newDuration = defaultInterval
248+
newDuration = defaultCPUSamplingTime
249249
}
250250

251251
opts.CPUSamplingTime = newDuration

0 commit comments

Comments
 (0)