mirror of
https://github.com/rclone/rclone.git
synced 2024-11-22 14:22:04 +08:00
fs: Don't stop calculating average transfer speed until the operation is complete
Currently, the average transfer speed will stop calculating 1 minute after the last queued transfer completes. This causes the average to stop calculating when checking is slow and the transfer queue becomes empty. This change will require all checks to complete before stopping the average speed calculation.
This commit is contained in:
parent
34195fd3e8
commit
ea4aa696a5
|
@ -777,7 +777,7 @@ func (s *StatsInfo) DoneTransferring(remote string, ok bool) {
|
|||
s.transfers++
|
||||
s.mu.Unlock()
|
||||
}
|
||||
if s.transferring.empty() {
|
||||
if s.transferring.empty() && s.checking.empty() {
|
||||
time.AfterFunc(averageStopAfter, s.stopAverageLoop)
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user