Implement --retries flag - fixes #109

This commit is contained in:
Nick Craig-Wood
2015-08-20 21:07:00 +01:00
parent dfe771fb0c
commit 0c6f816a49
2 changed files with 55 additions and 53 deletions
+7
View File
@@ -134,6 +134,13 @@ func (s *StatsInfo) ResetCounters() {
s.transfers = 0
}
// ResetErrors sets the errors count to 0
func (s *StatsInfo) ResetErrors() {
s.lock.RLock()
defer s.lock.RUnlock()
s.errors = 0
}
// Errored returns whether there have been any errors
func (s *StatsInfo) Errored() bool {
s.lock.RLock()