Commit 467bfa68 authored by jar@chromium.org's avatar jar@chromium.org

Revert of https://codereview.chromium.org/127463003/

Reason for revert: Reverting on Canary to maintain port selection there.  Will land on Dev branch.

TBR=wtc@chromium.org,rch@chromium.org
NOTREECHECKS=true
NOTRY=true
BUG=329255

Review URL: https://codereview.chromium.org/132603002

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@243979 0039d316-1c4b-4281-b951-d872f2087c98
parent 82cfca19
......@@ -514,14 +514,9 @@ int QuicStreamFactory::CreateSession(
IPEndPoint addr = *address_list.begin();
scoped_refptr<PortSuggester> port_suggester =
new PortSuggester(host_port_proxy_pair.first, port_seed_);
DatagramSocket::BindType bind_type = DatagramSocket::RANDOM_BIND;
#if defined(OS_WIN)
// TODO(jar)bug=329255 Provide better implementation to avoid pop-up warning.
bind_type = DatagramSocket::DEFAULT_BIND;
#endif
scoped_ptr<DatagramClientSocket> socket(
client_socket_factory_->CreateDatagramClientSocket(
bind_type,
DatagramSocket::RANDOM_BIND,
base::Bind(&PortSuggester::SuggestPort, port_suggester),
net_log.net_log(), net_log.source()));
int rv = socket->Connect(addr);
......@@ -529,12 +524,7 @@ int QuicStreamFactory::CreateSession(
return rv;
UMA_HISTOGRAM_COUNTS("Net.QuicEphemeralPortsSuggested",
port_suggester->call_count());
#if defined(OS_WIN)
// TODO(jar)bug=329255 Provide better implementation to avoid pop-up warning.
DCHECK_EQ(0u, port_suggester->call_count());
#else
DCHECK_LE(1u, port_suggester->call_count());
#endif
// We should adaptively set this buffer size, but for now, we'll use a size
// that is more than large enough for a full receive window, and yet
......
......@@ -576,11 +576,6 @@ TEST_P(QuicStreamFactoryTest, CancelCreate) {
}
TEST_P(QuicStreamFactoryTest, CreateConsistentEphemeralPort) {
#if defined(OS_WIN)
// TODO(jar)bug=329255 Provide better implementation to avoid pop-up warning.
return;
#endif
// Sequentially connect to the default host, then another host, and then the
// default host. Verify that the default host gets a consistent ephemeral
// port, that is different from the other host's connection.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment