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

Unified Diff: net/quic/core/congestion_control/cubic_bytes.cc

Issue 2524523002: Remove various 'using std::' statements from QUIC code and use (Closed)
Patch Set: Rebase Created 4 years 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/core/congestion_control/cubic_bytes.cc
diff --git a/net/quic/core/congestion_control/cubic_bytes.cc b/net/quic/core/congestion_control/cubic_bytes.cc
index fd7a945d10e806aa065ba104d3d7d68ccf84b5cc..bbc9f6963126fd88428f5f9bff2fa8f5ce2e56a3 100644
--- a/net/quic/core/congestion_control/cubic_bytes.cc
+++ b/net/quic/core/congestion_control/cubic_bytes.cc
@@ -12,8 +12,6 @@
#include "net/quic/core/quic_flags.h"
#include "net/quic/core/quic_packets.h"
-using std::max;
-using std::min;
namespace net {
@@ -121,8 +119,8 @@ QuicByteCount CubicBytes::CongestionWindowAfterAck(
// Cubic is "independent" of RTT, the update is limited by the time elapsed.
if (last_congestion_window_ == current_congestion_window &&
(current_time - last_update_time_ <= MaxCubicTimeInterval())) {
- return max(last_target_congestion_window_,
- estimated_tcp_congestion_window_);
+ return std::max(last_target_congestion_window_,
+ estimated_tcp_congestion_window_);
}
last_congestion_window_ = current_congestion_window;
last_update_time_ = current_time;
@@ -173,8 +171,8 @@ QuicByteCount CubicBytes::CongestionWindowAfterAck(
: origin_point_congestion_window_ - delta_congestion_window;
// Limit the CWND increase to half the acked bytes.
target_congestion_window =
- min(target_congestion_window,
- current_congestion_window + acked_bytes_count_ / 2);
+ std::min(target_congestion_window,
+ current_congestion_window + acked_bytes_count_ / 2);
DCHECK_LT(0u, estimated_tcp_congestion_window_);
// Increase the window by approximately Alpha * 1 MSS of bytes every
« no previous file with comments | « net/quic/core/congestion_control/cubic.cc ('k') | net/quic/core/congestion_control/general_loss_algorithm_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698