Update To 11.40.268.0
[platform/framework/web/crosswalk.git] / src / net / quic / quic_time_wait_list_manager.cc
index d1f3419..d59cbc4 100644 (file)
@@ -27,8 +27,9 @@ namespace net {
 
 namespace {
 
-// Time period for which the connection_id should live in time wait state..
-const int kTimeWaitSeconds = 5;
+// Time period for which a given connection_id should live in the time-wait
+// state.
+int64 FLAGS_quic_time_wait_list_seconds = 5;
 
 }  // namespace
 
@@ -41,7 +42,7 @@ class ConnectionIdCleanUpAlarm : public QuicAlarm::Delegate {
       QuicTimeWaitListManager* time_wait_list_manager)
       : time_wait_list_manager_(time_wait_list_manager) {}
 
-  virtual QuicTime OnAlarm() OVERRIDE {
+  QuicTime OnAlarm() override {
     time_wait_list_manager_->CleanUpOldConnectionIds();
     // Let the time wait manager register the alarm at appropriate time.
     return QuicTime::Zero();
@@ -86,7 +87,8 @@ QuicTimeWaitListManager::QuicTimeWaitListManager(
     QuicConnectionHelperInterface* helper,
     const QuicVersionVector& supported_versions)
     : helper_(helper),
-      kTimeWaitPeriod_(QuicTime::Delta::FromSeconds(kTimeWaitSeconds)),
+      kTimeWaitPeriod_(
+          QuicTime::Delta::FromSeconds(FLAGS_quic_time_wait_list_seconds)),
       connection_id_clean_up_alarm_(
           helper_->CreateAlarm(new ConnectionIdCleanUpAlarm(this))),
       writer_(writer),
@@ -274,6 +276,7 @@ void QuicTimeWaitListManager::CleanUpOldConnectionIds() {
       break;
     }
     // This connection_id has lived its age, retire it now.
+    DVLOG(1) << "Retiring " << it->first << " from the time-wait state.";
     delete it->second.close_packet;
     connection_id_map_.erase(it);
   }