fix race condition with timestamp
This commit is contained in:
parent
bcaf0e910c
commit
b67ac078b8
|
@ -47,10 +47,13 @@ func (r *RSS) Gather(acc telegraf.Accumulator) error {
|
|||
}
|
||||
|
||||
// remember last time started
|
||||
ts = time.Now()
|
||||
tsl := time.Now()
|
||||
|
||||
wg.Wait()
|
||||
|
||||
// set last time started
|
||||
ts = tsl
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue