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

Unified Diff: net/quic/congestion_control/rtt_stats.h

Issue 839143002: Roll Chrome into Mojo. (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Rebase Created 5 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/rtt_stats.h
diff --git a/net/quic/congestion_control/rtt_stats.h b/net/quic/congestion_control/rtt_stats.h
index 9dd5620b19ee3cf6a4afb66f7a4c782249831ad1..3d256d9ddfa10d468fb33930c6c15e1242a0ff8b 100644
--- a/net/quic/congestion_control/rtt_stats.h
+++ b/net/quic/congestion_control/rtt_stats.h
@@ -53,6 +53,10 @@ class NET_EXPORT_PRIVATE RttStats {
// Sets an initial RTT to be used for SmoothedRtt before any RTT updates.
void set_initial_rtt_us(int64 initial_rtt_us) {
+ if (initial_rtt_us <= 0) {
+ LOG(DFATAL) << "Attempt to set initial rtt to <= 0.";
+ return;
+ }
initial_rtt_us_ = initial_rtt_us;
}
« no previous file with comments | « net/quic/congestion_control/pacing_sender_test.cc ('k') | net/quic/crypto/quic_crypto_server_config_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698