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

Side by Side Diff: net/tools/quic/test_tools/quic_test_client.cc

Issue 683263003: Turning off CID truncation for proxied connections. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@Protect_UpdateRTT_from_negative_deltas_78580114
Patch Set: Created 6 years, 1 month 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/tools/quic/quic_client.h ('k') | no next file » | 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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/tools/quic/test_tools/quic_test_client.h" 5 #include "net/tools/quic/test_tools/quic_test_client.h"
6 6
7 #include "base/time/time.h" 7 #include "base/time/time.h"
8 #include "net/base/completion_callback.h" 8 #include "net/base/completion_callback.h"
9 #include "net/base/net_errors.h" 9 #include "net/base/net_errors.h"
10 #include "net/cert/cert_verify_result.h" 10 #include "net/cert/cert_verify_result.h"
(...skipping 203 matching lines...) Expand 10 before | Expand all | Expand 10 after
214 void QuicTestClient::Initialize(bool secure) { 214 void QuicTestClient::Initialize(bool secure) {
215 priority_ = 3; 215 priority_ = 3;
216 connect_attempted_ = false; 216 connect_attempted_ = false;
217 secure_ = secure; 217 secure_ = secure;
218 auto_reconnect_ = false; 218 auto_reconnect_ = false;
219 buffer_body_ = true; 219 buffer_body_ = true;
220 fec_policy_ = FEC_PROTECT_OPTIONAL; 220 fec_policy_ = FEC_PROTECT_OPTIONAL;
221 proof_verifier_ = nullptr; 221 proof_verifier_ = nullptr;
222 ClearPerRequestState(); 222 ClearPerRequestState();
223 ExpectCertificates(secure_); 223 ExpectCertificates(secure_);
224 // As chrome will generally do this, we want it to be the default when it's
225 // not overridden.
226 if (!client_->config()->HasSetBytesForConnectionIdToSend()) {
227 client_->config()->SetBytesForConnectionIdToSend(0);
228 }
224 } 229 }
225 230
226 void QuicTestClient::ExpectCertificates(bool on) { 231 void QuicTestClient::ExpectCertificates(bool on) {
227 if (on) { 232 if (on) {
228 proof_verifier_ = new RecordingProofVerifier; 233 proof_verifier_ = new RecordingProofVerifier;
229 client_->SetProofVerifier(proof_verifier_); 234 client_->SetProofVerifier(proof_verifier_);
230 } else { 235 } else {
231 proof_verifier_ = nullptr; 236 proof_verifier_ = nullptr;
232 client_->SetProofVerifier(nullptr); 237 client_->SetProofVerifier(nullptr);
233 } 238 }
(...skipping 325 matching lines...) Expand 10 before | Expand all | Expand 10 after
559 // Set policy for headers and crypto streams. 564 // Set policy for headers and crypto streams.
560 ReliableQuicStreamPeer::SetFecPolicy( 565 ReliableQuicStreamPeer::SetFecPolicy(
561 QuicSessionPeer::GetHeadersStream(client()->session()), fec_policy); 566 QuicSessionPeer::GetHeadersStream(client()->session()), fec_policy);
562 ReliableQuicStreamPeer::SetFecPolicy(client()->session()->GetCryptoStream(), 567 ReliableQuicStreamPeer::SetFecPolicy(client()->session()->GetCryptoStream(),
563 fec_policy); 568 fec_policy);
564 } 569 }
565 570
566 } // namespace test 571 } // namespace test
567 } // namespace tools 572 } // namespace tools
568 } // namespace net 573 } // namespace net
OLDNEW
« no previous file with comments | « net/tools/quic/quic_client.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698