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

Side by Side Diff: net/socket/next_proto.cc

Issue 851503003: Update from https://crrev.com/311076 (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: 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 unified diff | Download patch
« no previous file with comments | « net/socket/client_socket_pool_manager_impl.cc ('k') | net/socket/socket_test_util.h » ('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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/socket/next_proto.h" 5 #include "net/socket/next_proto.h"
6 6
7 namespace net { 7 namespace net {
8 8
9 NextProtoVector NextProtosHttpOnly() { 9 NextProtoVector NextProtosHttpOnly() {
10 NextProtoVector next_protos; 10 NextProtoVector next_protos;
11 next_protos.push_back(kProtoHTTP11); 11 next_protos.push_back(kProtoHTTP11);
12 return next_protos; 12 return next_protos;
13 } 13 }
14 14
15 NextProtoVector NextProtosDefaults() { 15 NextProtoVector NextProtosDefaults() {
16 NextProtoVector next_protos; 16 NextProtoVector next_protos;
17 next_protos.push_back(kProtoHTTP11); 17 next_protos.push_back(kProtoHTTP11);
18 next_protos.push_back(kProtoSPDY31); 18 next_protos.push_back(kProtoSPDY31);
19 next_protos.push_back(kProtoSPDY4_14); 19 next_protos.push_back(kProtoSPDY4_14);
20 next_protos.push_back(kProtoSPDY4_15);
21 return next_protos; 20 return next_protos;
22 } 21 }
23 22
24 NextProtoVector NextProtosWithSpdyAndQuic(bool spdy_enabled, 23 NextProtoVector NextProtosWithSpdyAndQuic(bool spdy_enabled,
25 bool quic_enabled) { 24 bool quic_enabled) {
26 NextProtoVector next_protos; 25 NextProtoVector next_protos;
27 next_protos.push_back(kProtoHTTP11); 26 next_protos.push_back(kProtoHTTP11);
28 if (quic_enabled) 27 if (quic_enabled)
29 next_protos.push_back(kProtoQUIC1SPDY3); 28 next_protos.push_back(kProtoQUIC1SPDY3);
30 if (spdy_enabled) { 29 if (spdy_enabled) {
31 next_protos.push_back(kProtoSPDY31); 30 next_protos.push_back(kProtoSPDY31);
32 next_protos.push_back(kProtoSPDY4_14); 31 next_protos.push_back(kProtoSPDY4_14);
33 next_protos.push_back(kProtoSPDY4_15);
34 } 32 }
35 return next_protos; 33 return next_protos;
36 } 34 }
37 35
38 NextProtoVector NextProtosSpdy31() { 36 NextProtoVector NextProtosSpdy31() {
39 NextProtoVector next_protos; 37 NextProtoVector next_protos;
40 next_protos.push_back(kProtoHTTP11); 38 next_protos.push_back(kProtoHTTP11);
41 next_protos.push_back(kProtoQUIC1SPDY3); 39 next_protos.push_back(kProtoQUIC1SPDY3);
42 next_protos.push_back(kProtoSPDY31); 40 next_protos.push_back(kProtoSPDY31);
43 return next_protos; 41 return next_protos;
44 } 42 }
45 43
46 NextProtoVector NextProtosSpdy4Http2() { 44 NextProtoVector NextProtosSpdy4Http2() {
47 NextProtoVector next_protos; 45 NextProtoVector next_protos;
48 next_protos.push_back(kProtoHTTP11); 46 next_protos.push_back(kProtoHTTP11);
49 next_protos.push_back(kProtoQUIC1SPDY3); 47 next_protos.push_back(kProtoQUIC1SPDY3);
50 next_protos.push_back(kProtoSPDY31); 48 next_protos.push_back(kProtoSPDY31);
51 next_protos.push_back(kProtoSPDY4_14); 49 next_protos.push_back(kProtoSPDY4_14);
52 next_protos.push_back(kProtoSPDY4_15);
53 return next_protos; 50 return next_protos;
54 } 51 }
55 52
56 } // namespace net 53 } // namespace net
OLDNEW
« no previous file with comments | « net/socket/client_socket_pool_manager_impl.cc ('k') | net/socket/socket_test_util.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698