diff options
author | joi@chromium.org <joi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-03-27 14:02:39 +0000 |
---|---|---|
committer | joi@chromium.org <joi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-03-27 14:02:39 +0000 |
commit | fc040af06e16a7d629e3239d53facccc66368dd7 (patch) | |
tree | ae05343e0c2b21094de8ed762adfc21b8ebfca35 /net | |
parent | 6bee18dcaaee29057f32f5764ca1f794285fe5f4 (diff) | |
download | chromium_src-fc040af06e16a7d629e3239d53facccc66368dd7.zip chromium_src-fc040af06e16a7d629e3239d53facccc66368dd7.tar.gz chromium_src-fc040af06e16a7d629e3239d53facccc66368dd7.tar.bz2 |
Remove BackoffEntry TODO that was wrong.
Clarify comment to illustrate why the current behavior is correct.
BUG=None
Review URL: https://chromiumcodereview.appspot.com/9773032
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@129177 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net')
-rw-r--r-- | net/base/backoff_entry.cc | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/net/base/backoff_entry.cc b/net/base/backoff_entry.cc index 683bebf..f00dd40 100644 --- a/net/base/backoff_entry.cc +++ b/net/base/backoff_entry.cc @@ -1,4 +1,4 @@ -// Copyright (c) 2011 The Chromium Authors. All rights reserved. +// Copyright (c) 2012 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. @@ -30,13 +30,11 @@ void BackoffEntry::InformOfRequest(bool succeeded) { ++failure_count_; exponential_backoff_release_time_ = CalculateReleaseTime(); } else { - // We slowly decay the number of times delayed instead of resetting it to 0 - // in order to stay stable if we receive successes interleaved between lots - // of failures. - // - // TODO(joi): Revisit this; it might be most correct to go to zero - // but have a way to go back to "old error count +1" if there is - // another error soon after. + // We slowly decay the number of times delayed instead of + // resetting it to 0 in order to stay stable if we receive + // successes interleaved between lots of failures. Note that in + // the normal case, the calculated release time (in the next + // statement) will be in the past once the method returns. if (failure_count_ > 0) --failure_count_; |