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

Side by Side Diff: net/quic/core/quic_version_manager.cc

Issue 2808273006: Landing Recent QUIC changes until Sun Apr 9 16:12:55 (Closed)
Patch Set: increment enabled_options in e2e test Created 3 years, 8 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 unified diff | Download patch
« no previous file with comments | « net/quic/core/quic_version_manager.h ('k') | net/quic/core/quic_version_manager_test.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2016 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "net/quic/core/quic_version_manager.h" 5 #include "net/quic/core/quic_version_manager.h"
6 6
7 #include "net/quic/core/quic_flags.h" 7 #include "net/quic/core/quic_flags.h"
8 #include "net/quic/core/quic_versions.h" 8 #include "net/quic/core/quic_versions.h"
9 9
10 namespace net { 10 namespace net {
11 11
12 QuicVersionManager::QuicVersionManager(QuicVersionVector supported_versions) 12 QuicVersionManager::QuicVersionManager(QuicVersionVector supported_versions)
13 : enable_version_38_(FLAGS_quic_enable_version_38), 13 : enable_version_39_(base::GetFlag(FLAGS_quic_enable_version_39)),
14 enable_version_38_(FLAGS_quic_reloadable_flag_quic_enable_version_38),
14 enable_version_37_(FLAGS_quic_reloadable_flag_quic_enable_version_37), 15 enable_version_37_(FLAGS_quic_reloadable_flag_quic_enable_version_37),
15 enable_version_36_(FLAGS_quic_reloadable_flag_quic_enable_version_36_v3), 16 enable_version_36_(FLAGS_quic_reloadable_flag_quic_enable_version_36_v3),
16 disable_version_34_(FLAGS_quic_reloadable_flag_quic_disable_version_34), 17 disable_version_34_(FLAGS_quic_reloadable_flag_quic_disable_version_34),
17 allowed_supported_versions_(supported_versions), 18 allowed_supported_versions_(supported_versions),
18 filtered_supported_versions_( 19 filtered_supported_versions_(
19 FilterSupportedVersions(supported_versions)) {} 20 FilterSupportedVersions(supported_versions)) {}
20 21
21 QuicVersionManager::~QuicVersionManager() {} 22 QuicVersionManager::~QuicVersionManager() {}
22 23
23 const QuicVersionVector& QuicVersionManager::GetSupportedVersions() { 24 const QuicVersionVector& QuicVersionManager::GetSupportedVersions() {
24 MaybeRefilterSupportedVersions(); 25 MaybeRefilterSupportedVersions();
25 return filtered_supported_versions_; 26 return filtered_supported_versions_;
26 } 27 }
27 28
28 void QuicVersionManager::MaybeRefilterSupportedVersions() { 29 void QuicVersionManager::MaybeRefilterSupportedVersions() {
29 if (enable_version_38_ != FLAGS_quic_enable_version_38 || 30 if (enable_version_39_ != base::GetFlag(FLAGS_quic_enable_version_39) ||
31 enable_version_38_ != FLAGS_quic_reloadable_flag_quic_enable_version_38 ||
30 enable_version_37_ != FLAGS_quic_reloadable_flag_quic_enable_version_37 || 32 enable_version_37_ != FLAGS_quic_reloadable_flag_quic_enable_version_37 ||
31 enable_version_36_ != 33 enable_version_36_ !=
32 FLAGS_quic_reloadable_flag_quic_enable_version_36_v3 || 34 FLAGS_quic_reloadable_flag_quic_enable_version_36_v3 ||
33 disable_version_34_ != 35 disable_version_34_ !=
34 FLAGS_quic_reloadable_flag_quic_disable_version_34) { 36 FLAGS_quic_reloadable_flag_quic_disable_version_34) {
35 enable_version_38_ = FLAGS_quic_enable_version_38; 37 enable_version_39_ = base::GetFlag(FLAGS_quic_enable_version_39);
38 enable_version_38_ = FLAGS_quic_reloadable_flag_quic_enable_version_38;
36 enable_version_37_ = FLAGS_quic_reloadable_flag_quic_enable_version_37; 39 enable_version_37_ = FLAGS_quic_reloadable_flag_quic_enable_version_37;
37 enable_version_36_ = FLAGS_quic_reloadable_flag_quic_enable_version_36_v3; 40 enable_version_36_ = FLAGS_quic_reloadable_flag_quic_enable_version_36_v3;
38 disable_version_34_ = FLAGS_quic_reloadable_flag_quic_disable_version_34; 41 disable_version_34_ = FLAGS_quic_reloadable_flag_quic_disable_version_34;
39 RefilterSupportedVersions(); 42 RefilterSupportedVersions();
40 } 43 }
41 } 44 }
42 45
43 void QuicVersionManager::RefilterSupportedVersions() { 46 void QuicVersionManager::RefilterSupportedVersions() {
44 filtered_supported_versions_ = 47 filtered_supported_versions_ =
45 FilterSupportedVersions(allowed_supported_versions_); 48 FilterSupportedVersions(allowed_supported_versions_);
46 } 49 }
47 50
48 } // namespace net 51 } // namespace net
OLDNEW
« no previous file with comments | « net/quic/core/quic_version_manager.h ('k') | net/quic/core/quic_version_manager_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698