Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(248)

Unified Diff: net/quic/congestion_control/hybrid_slow_start.cc

Issue 125403006: Various QUIC cleanups to sync with internal code. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix comments Created 6 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: net/quic/congestion_control/hybrid_slow_start.cc
diff --git a/net/quic/congestion_control/hybrid_slow_start.cc b/net/quic/congestion_control/hybrid_slow_start.cc
index 0edb10e86ea092024941e9821cd6358d93708e11..3a6b0ec6cc2113097a133eb30591b8d14e7befe7 100644
--- a/net/quic/congestion_control/hybrid_slow_start.cc
+++ b/net/quic/congestion_control/hybrid_slow_start.cc
@@ -6,6 +6,9 @@
#include <algorithm>
+using std::max;
+using std::min;
+
namespace net {
// Note(pwestin): the magic clamping numbers come from the original code in
@@ -86,10 +89,10 @@ void HybridSlowStart::Update(QuicTime::Delta rtt, QuicTime::Delta delay_min) {
if (sample_count_ == kHybridStartMinSamples) {
int accepted_variance_us = delay_min.ToMicroseconds() >>
kHybridStartDelayFactorExp;
- accepted_variance_us = std::min(accepted_variance_us,
- kHybridStartDelayMaxThresholdUs);
+ accepted_variance_us = min(accepted_variance_us,
+ kHybridStartDelayMaxThresholdUs);
QuicTime::Delta accepted_variance = QuicTime::Delta::FromMicroseconds(
- std::max(accepted_variance_us, kHybridStartDelayMinThresholdUs));
+ max(accepted_variance_us, kHybridStartDelayMinThresholdUs));
if (current_rtt_ > delay_min.Add(accepted_variance)) {
found_delay_ = true;
« no previous file with comments | « net/quic/congestion_control/fix_rate_sender.cc ('k') | net/quic/congestion_control/inter_arrival_bitrate_ramp_up.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698