summaryrefslogtreecommitdiffstats
path: root/net/spdy
diff options
context:
space:
mode:
authorrch@chromium.org <rch@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-04-01 01:28:53 +0000
committerrch@chromium.org <rch@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-04-01 01:28:53 +0000
commit314b03990f31330e847c384fbb9426ca5e6c1a58 (patch)
tree52eff81fb4eb0b127ef56ace4c8e3b155e8513ed /net/spdy
parent9decc62c6eb9f834323498611f8e112ff240aa14 (diff)
downloadchromium_src-314b03990f31330e847c384fbb9426ca5e6c1a58.zip
chromium_src-314b03990f31330e847c384fbb9426ca5e6c1a58.tar.gz
chromium_src-314b03990f31330e847c384fbb9426ca5e6c1a58.tar.bz2
Rename PrivateMode enum values:
kPrivacyModeDisabled => PRIVACY_MODE_DISABLED kPrivacyModeEnabled => PRIVACY_MODE_ENABLED To match the chromium style guide: Though the Google C++ Style Guide now says to use kConstantNaming for enums, Chromium was written using MACRO_STYLE naming. Continue to use this style for consistency. R=mef@chromium.org Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=260281 Review URL: https://codereview.chromium.org/215023002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@260729 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/spdy')
-rw-r--r--net/spdy/spdy_http_stream_unittest.cc14
-rw-r--r--net/spdy/spdy_network_transaction_unittest.cc6
-rw-r--r--net/spdy/spdy_proxy_client_socket_unittest.cc2
-rw-r--r--net/spdy/spdy_session_key.cc2
-rw-r--r--net/spdy/spdy_session_pool.cc2
-rw-r--r--net/spdy/spdy_session_pool_unittest.cc14
-rw-r--r--net/spdy/spdy_session_unittest.cc14
-rw-r--r--net/spdy/spdy_stream_unittest.cc2
-rw-r--r--net/spdy/spdy_websocket_stream_unittest.cc2
9 files changed, 29 insertions, 29 deletions
diff --git a/net/spdy/spdy_http_stream_unittest.cc b/net/spdy/spdy_http_stream_unittest.cc
index 2142d58..d9e63f9 100644
--- a/net/spdy/spdy_http_stream_unittest.cc
+++ b/net/spdy/spdy_http_stream_unittest.cc
@@ -143,7 +143,7 @@ TEST_P(SpdyHttpStreamTest, GetUploadProgressBeforeInitialization) {
HostPortPair host_port_pair("www.google.com", 80);
SpdySessionKey key(host_port_pair, ProxyServer::Direct(),
- kPrivacyModeDisabled);
+ PRIVACY_MODE_DISABLED);
InitSession(reads, arraysize(reads), NULL, 0, key);
SpdyHttpStream stream(session_, false);
@@ -169,7 +169,7 @@ TEST_P(SpdyHttpStreamTest, SendRequest) {
HostPortPair host_port_pair("www.google.com", 80);
SpdySessionKey key(host_port_pair, ProxyServer::Direct(),
- kPrivacyModeDisabled);
+ PRIVACY_MODE_DISABLED);
InitSession(reads, arraysize(reads), writes, arraysize(writes), key);
HttpRequestInfo request;
@@ -244,7 +244,7 @@ TEST_P(SpdyHttpStreamTest, LoadTimingTwoRequests) {
HostPortPair host_port_pair("www.google.com", 80);
SpdySessionKey key(host_port_pair, ProxyServer::Direct(),
- kPrivacyModeDisabled);
+ PRIVACY_MODE_DISABLED);
InitSessionDeterministic(reads, arraysize(reads),
writes, arraysize(writes),
key);
@@ -333,7 +333,7 @@ TEST_P(SpdyHttpStreamTest, SendChunkedPost) {
HostPortPair host_port_pair("www.google.com", 80);
SpdySessionKey key(host_port_pair, ProxyServer::Direct(),
- kPrivacyModeDisabled);
+ PRIVACY_MODE_DISABLED);
InitSession(vector_as_array(&reads), reads.size(),
vector_as_array(&writes), writes.size(),
key);
@@ -409,7 +409,7 @@ TEST_P(SpdyHttpStreamTest, DelayedSendChunkedPost) {
HostPortPair host_port_pair("www.google.com", 80);
SpdySessionKey key(host_port_pair, ProxyServer::Direct(),
- kPrivacyModeDisabled);
+ PRIVACY_MODE_DISABLED);
InitSessionDeterministic(reads, arraysize(reads),
writes, arraysize(writes),
key);
@@ -503,7 +503,7 @@ TEST_P(SpdyHttpStreamTest, SpdyURLTest) {
HostPortPair host_port_pair("www.google.com", 80);
SpdySessionKey key(host_port_pair, ProxyServer::Direct(),
- kPrivacyModeDisabled);
+ PRIVACY_MODE_DISABLED);
InitSession(reads, arraysize(reads), writes, arraysize(writes), key);
HttpRequestInfo request;
@@ -562,7 +562,7 @@ TEST_P(SpdyHttpStreamTest, DelayedSendChunkedPostWithWindowUpdate) {
HostPortPair host_port_pair("www.google.com", 80);
SpdySessionKey key(host_port_pair, ProxyServer::Direct(),
- kPrivacyModeDisabled);
+ PRIVACY_MODE_DISABLED);
InitSessionDeterministic(reads, arraysize(reads),
writes, arraysize(writes),
diff --git a/net/spdy/spdy_network_transaction_unittest.cc b/net/spdy/spdy_network_transaction_unittest.cc
index 89451ea..51db006 100644
--- a/net/spdy/spdy_network_transaction_unittest.cc
+++ b/net/spdy/spdy_network_transaction_unittest.cc
@@ -588,7 +588,7 @@ class SpdyNetworkTransactionTest
int port = helper.test_params().ssl_type == SPDYNPN ? 443 : 80;
HostPortPair host_port_pair(url.host(), port);
SpdySessionKey key(host_port_pair, ProxyServer::Direct(),
- kPrivacyModeDisabled);
+ PRIVACY_MODE_DISABLED);
BoundNetLog log;
const scoped_refptr<HttpNetworkSession>& session = helper.session();
base::WeakPtr<SpdySession> spdy_session =
@@ -4770,12 +4770,12 @@ TEST_P(SpdyNetworkTransactionTest, DirectConnectProxyReconnect) {
// Check that the SpdySession is still in the SpdySessionPool.
HostPortPair host_port_pair("www.google.com", helper.port());
SpdySessionKey session_pool_key_direct(
- host_port_pair, ProxyServer::Direct(), kPrivacyModeDisabled);
+ host_port_pair, ProxyServer::Direct(), PRIVACY_MODE_DISABLED);
EXPECT_TRUE(HasSpdySession(spdy_session_pool, session_pool_key_direct));
SpdySessionKey session_pool_key_proxy(
host_port_pair,
ProxyServer::FromURI("www.foo.com", ProxyServer::SCHEME_HTTP),
- kPrivacyModeDisabled);
+ PRIVACY_MODE_DISABLED);
EXPECT_FALSE(HasSpdySession(spdy_session_pool, session_pool_key_proxy));
// Set up data for the proxy connection.
diff --git a/net/spdy/spdy_proxy_client_socket_unittest.cc b/net/spdy/spdy_proxy_client_socket_unittest.cc
index 18fef79..653504d 100644
--- a/net/spdy/spdy_proxy_client_socket_unittest.cc
+++ b/net/spdy/spdy_proxy_client_socket_unittest.cc
@@ -158,7 +158,7 @@ SpdyProxyClientSocketTest::SpdyProxyClientSocketTest()
proxy_(ProxyServer::SCHEME_HTTPS, proxy_host_port_),
endpoint_spdy_session_key_(endpoint_host_port_pair_,
proxy_,
- kPrivacyModeDisabled) {
+ PRIVACY_MODE_DISABLED) {
session_deps_.net_log = net_log_.bound().net_log();
}
diff --git a/net/spdy/spdy_session_key.cc b/net/spdy/spdy_session_key.cc
index 3d6cdea..3ef95de 100644
--- a/net/spdy/spdy_session_key.cc
+++ b/net/spdy/spdy_session_key.cc
@@ -8,7 +8,7 @@
namespace net {
-SpdySessionKey::SpdySessionKey() : privacy_mode_(kPrivacyModeDisabled) {
+SpdySessionKey::SpdySessionKey() : privacy_mode_(PRIVACY_MODE_DISABLED) {
}
SpdySessionKey::SpdySessionKey(const HostPortPair& host_port_pair,
diff --git a/net/spdy/spdy_session_pool.cc b/net/spdy/spdy_session_pool.cc
index 6ce0a93..4747f05 100644
--- a/net/spdy/spdy_session_pool.cc
+++ b/net/spdy/spdy_session_pool.cc
@@ -323,7 +323,7 @@ const SpdySessionKey& SpdySessionPool::NormalizeListKey(
HostPortPair single_domain = HostPortPair("singledomain.com", 80);
single_domain_key = new SpdySessionKey(single_domain,
ProxyServer::Direct(),
- kPrivacyModeDisabled);
+ PRIVACY_MODE_DISABLED);
}
return *single_domain_key;
}
diff --git a/net/spdy/spdy_session_pool_unittest.cc b/net/spdy/spdy_session_pool_unittest.cc
index c9873fc..f246dd0 100644
--- a/net/spdy/spdy_session_pool_unittest.cc
+++ b/net/spdy/spdy_session_pool_unittest.cc
@@ -96,7 +96,7 @@ TEST_P(SpdySessionPoolTest, CloseCurrentSessions) {
SpdySessionKey test_key =
SpdySessionKey(
test_host_port_pair, ProxyServer::Direct(),
- kPrivacyModeDisabled);
+ PRIVACY_MODE_DISABLED);
MockConnect connect_data(SYNCHRONOUS, OK);
MockRead reads[] = {
@@ -157,7 +157,7 @@ TEST_P(SpdySessionPoolTest, CloseCurrentIdleSessions) {
const std::string kTestHost1("http://www.a.com");
HostPortPair test_host_port_pair1(kTestHost1, 80);
SpdySessionKey key1(test_host_port_pair1, ProxyServer::Direct(),
- kPrivacyModeDisabled);
+ PRIVACY_MODE_DISABLED);
base::WeakPtr<SpdySession> session1 =
CreateInsecureSpdySession(http_session_, key1, BoundNetLog());
GURL url1(kTestHost1);
@@ -171,7 +171,7 @@ TEST_P(SpdySessionPoolTest, CloseCurrentIdleSessions) {
const std::string kTestHost2("http://www.b.com");
HostPortPair test_host_port_pair2(kTestHost2, 80);
SpdySessionKey key2(test_host_port_pair2, ProxyServer::Direct(),
- kPrivacyModeDisabled);
+ PRIVACY_MODE_DISABLED);
base::WeakPtr<SpdySession> session2 =
CreateInsecureSpdySession(http_session_, key2, BoundNetLog());
GURL url2(kTestHost2);
@@ -185,7 +185,7 @@ TEST_P(SpdySessionPoolTest, CloseCurrentIdleSessions) {
const std::string kTestHost3("http://www.c.com");
HostPortPair test_host_port_pair3(kTestHost3, 80);
SpdySessionKey key3(test_host_port_pair3, ProxyServer::Direct(),
- kPrivacyModeDisabled);
+ PRIVACY_MODE_DISABLED);
base::WeakPtr<SpdySession> session3 =
CreateInsecureSpdySession(http_session_, key3, BoundNetLog());
GURL url3(kTestHost3);
@@ -259,7 +259,7 @@ TEST_P(SpdySessionPoolTest, CloseAllSessions) {
SpdySessionKey test_key =
SpdySessionKey(
test_host_port_pair, ProxyServer::Direct(),
- kPrivacyModeDisabled);
+ PRIVACY_MODE_DISABLED);
MockConnect connect_data(SYNCHRONOUS, OK);
MockRead reads[] = {
@@ -348,7 +348,7 @@ void SpdySessionPoolTest::RunIPPoolingTest(
// Setup a SpdySessionKey
test_hosts[i].key = SpdySessionKey(
HostPortPair(test_hosts[i].name, kTestPort), ProxyServer::Direct(),
- kPrivacyModeDisabled);
+ PRIVACY_MODE_DISABLED);
}
MockConnect connect_data(SYNCHRONOUS, OK);
@@ -382,7 +382,7 @@ void SpdySessionPoolTest::RunIPPoolingTest(
// Verify that the second host, through a proxy, won't share the IP.
SpdySessionKey proxy_key(test_hosts[1].key.host_port_pair(),
ProxyServer::FromPacString("HTTP http://proxy.foo.com/"),
- kPrivacyModeDisabled);
+ PRIVACY_MODE_DISABLED);
EXPECT_FALSE(HasSpdySession(spdy_session_pool_, proxy_key));
// Overlap between 2 and 3 does is not transitive to 1.
diff --git a/net/spdy/spdy_session_unittest.cc b/net/spdy/spdy_session_unittest.cc
index a5d9292..f3fb735 100644
--- a/net/spdy/spdy_session_unittest.cc
+++ b/net/spdy/spdy_session_unittest.cc
@@ -107,7 +107,7 @@ class SpdySessionTest : public PlatformTest,
test_url_(kTestUrl),
test_host_port_pair_(kTestHost, kTestPort),
key_(test_host_port_pair_, ProxyServer::Direct(),
- kPrivacyModeDisabled) {
+ PRIVACY_MODE_DISABLED) {
}
virtual ~SpdySessionTest() {
@@ -2719,7 +2719,7 @@ TEST_P(SpdySessionTest, CloseOneIdleConnection) {
// Create an idle SPDY session.
SpdySessionKey key1(HostPortPair("1.com", 80), ProxyServer::Direct(),
- kPrivacyModeDisabled);
+ PRIVACY_MODE_DISABLED);
base::WeakPtr<SpdySession> session1 =
CreateInsecureSpdySession(http_session_, key1, BoundNetLog());
EXPECT_FALSE(pool->IsStalled());
@@ -2779,14 +2779,14 @@ TEST_P(SpdySessionTest, CloseOneIdleConnectionWithAlias) {
// Create an idle SPDY session.
SpdySessionKey key1(HostPortPair("1.com", 80), ProxyServer::Direct(),
- kPrivacyModeDisabled);
+ PRIVACY_MODE_DISABLED);
base::WeakPtr<SpdySession> session1 =
CreateInsecureSpdySession(http_session_, key1, BoundNetLog());
EXPECT_FALSE(pool->IsStalled());
// Set up an alias for the idle SPDY session, increasing its ref count to 2.
SpdySessionKey key2(HostPortPair("2.com", 80), ProxyServer::Direct(),
- kPrivacyModeDisabled);
+ PRIVACY_MODE_DISABLED);
HostResolver::RequestInfo info(key2.host_port_pair());
AddressList addresses;
// Pre-populate the DNS cache, since a synchronous resolution is required in
@@ -2867,7 +2867,7 @@ TEST_P(SpdySessionTest, CloseSessionOnIdleWhenPoolStalled) {
// Create a SPDY session.
GURL url1(kDefaultURL);
SpdySessionKey key1(HostPortPair(url1.host(), 80),
- ProxyServer::Direct(), kPrivacyModeDisabled);
+ ProxyServer::Direct(), PRIVACY_MODE_DISABLED);
base::WeakPtr<SpdySession> session1 =
CreateInsecureSpdySession(http_session_, key1, BoundNetLog());
EXPECT_FALSE(pool->IsStalled());
@@ -2928,9 +2928,9 @@ TEST_P(SpdySessionTest, SpdySessionKeyPrivacyMode) {
HostPortPair host_port_pair("www.google.com", 443);
SpdySessionKey key_privacy_enabled(host_port_pair, ProxyServer::Direct(),
- kPrivacyModeEnabled);
+ PRIVACY_MODE_ENABLED);
SpdySessionKey key_privacy_disabled(host_port_pair, ProxyServer::Direct(),
- kPrivacyModeDisabled);
+ PRIVACY_MODE_DISABLED);
EXPECT_FALSE(HasSpdySession(spdy_session_pool_, key_privacy_enabled));
EXPECT_FALSE(HasSpdySession(spdy_session_pool_, key_privacy_disabled));
diff --git a/net/spdy/spdy_stream_unittest.cc b/net/spdy/spdy_stream_unittest.cc
index cc1386d..d6bf58d 100644
--- a/net/spdy/spdy_stream_unittest.cc
+++ b/net/spdy/spdy_stream_unittest.cc
@@ -53,7 +53,7 @@ class SpdyStreamTest : public ::testing::Test,
base::WeakPtr<SpdySession> CreateDefaultSpdySession() {
SpdySessionKey key(HostPortPair("www.google.com", 80),
ProxyServer::Direct(),
- kPrivacyModeDisabled);
+ PRIVACY_MODE_DISABLED);
return CreateInsecureSpdySession(session_, key, BoundNetLog());
}
diff --git a/net/spdy/spdy_websocket_stream_unittest.cc b/net/spdy/spdy_websocket_stream_unittest.cc
index 1813947..3330e59 100644
--- a/net/spdy/spdy_websocket_stream_unittest.cc
+++ b/net/spdy/spdy_websocket_stream_unittest.cc
@@ -201,7 +201,7 @@ class SpdyWebSocketStreamTest
host_port_pair_.set_port(80);
spdy_session_key_ = SpdySessionKey(host_port_pair_,
ProxyServer::Direct(),
- kPrivacyModeDisabled);
+ PRIVACY_MODE_DISABLED);
spdy_settings_to_send_[spdy_settings_id_to_set_] =
SettingsFlagsAndValue(