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

Unified Diff: net/quic/test_tools/quic_test_utils.cc

Issue 1667583004: Landing Recent QUIC changes until 01/31/2016 05:22 UTC (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@Final_0203
Patch Set: Rebase Created 4 years, 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/quic/test_tools/quic_packet_creator_peer.cc ('k') | net/tools/quic/end_to_end_test.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/quic/test_tools/quic_test_utils.cc
diff --git a/net/quic/test_tools/quic_test_utils.cc b/net/quic/test_tools/quic_test_utils.cc
index ecd0b2e508d9672946db9b37618bfea148074930..b27203e0f55702176ba4016217c078f90e54e93c 100644
--- a/net/quic/test_tools/quic_test_utils.cc
+++ b/net/quic/test_tools/quic_test_utils.cc
@@ -295,11 +295,8 @@ PacketSavingConnection::~PacketSavingConnection() {
}
void PacketSavingConnection::SendOrQueuePacket(SerializedPacket* packet) {
- if (!packet->packet->owns_buffer()) {
- scoped_ptr<QuicEncryptedPacket> encrypted_deleter(packet->packet);
- packet->packet = packet->packet->Clone();
- }
- encrypted_packets_.push_back(packet->packet);
+ encrypted_packets_.push_back(new QuicEncryptedPacket(
+ QuicUtils::CopyBuffer(*packet), packet->encrypted_length, true));
// Transfer ownership of the packet to the SentPacketManager and the
// ack notifier to the AckNotifierManager.
sent_packet_manager_.OnPacketSent(packet, 0, QuicTime::Zero(), 1000,
@@ -357,7 +354,7 @@ TestQuicSpdyClientSession::TestQuicSpdyClientSession(
: QuicClientSessionBase(connection, &push_promise_index_, config) {
crypto_stream_.reset(new QuicCryptoClientStream(
server_id, this, CryptoTestUtils::ProofVerifyContextForTesting(),
- crypto_config));
+ crypto_config, this));
Initialize();
}
« no previous file with comments | « net/quic/test_tools/quic_packet_creator_peer.cc ('k') | net/tools/quic/end_to_end_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698