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

Side by Side Diff: net/quic/test_tools/quic_packet_creator_peer.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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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/quic/test_tools/quic_packet_creator_peer.h" 5 #include "net/quic/test_tools/quic_packet_creator_peer.h"
6 6
7 #include "net/quic/quic_packet_creator.h" 7 #include "net/quic/quic_packet_creator.h"
8 8
9 namespace net { 9 namespace net {
10 namespace test { 10 namespace test {
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after
119 size_t buffer_len) { 119 size_t buffer_len) {
120 DCHECK(creator->queued_frames_.empty()); 120 DCHECK(creator->queued_frames_.empty());
121 DCHECK(!frames.empty()); 121 DCHECK(!frames.empty());
122 for (const QuicFrame& frame : frames) { 122 for (const QuicFrame& frame : frames) {
123 bool success = creator->AddFrame(frame, false); 123 bool success = creator->AddFrame(frame, false);
124 DCHECK(success); 124 DCHECK(success);
125 } 125 }
126 creator->SerializePacket(buffer, buffer_len); 126 creator->SerializePacket(buffer, buffer_len);
127 SerializedPacket packet = creator->packet_; 127 SerializedPacket packet = creator->packet_;
128 // The caller takes ownership of the QuicEncryptedPacket. 128 // The caller takes ownership of the QuicEncryptedPacket.
129 creator->packet_.packet = nullptr; 129 creator->packet_.encrypted_buffer = nullptr;
130 DCHECK(packet.retransmittable_frames.empty()); 130 DCHECK(packet.retransmittable_frames.empty());
131 return packet; 131 return packet;
132 } 132 }
133 133
134 // static 134 // static
135 void QuicPacketCreatorPeer::ResetFecGroup(QuicPacketCreator* creator) { 135 void QuicPacketCreatorPeer::ResetFecGroup(QuicPacketCreator* creator) {
136 creator->ResetFecGroup(); 136 creator->ResetFecGroup();
137 } 137 }
138 138
139 // static 139 // static
(...skipping 14 matching lines...) Expand all
154 return creator->packet_.encryption_level; 154 return creator->packet_.encryption_level;
155 } 155 }
156 156
157 // static 157 // static
158 QuicPathId QuicPacketCreatorPeer::GetCurrentPath(QuicPacketCreator* creator) { 158 QuicPathId QuicPacketCreatorPeer::GetCurrentPath(QuicPacketCreator* creator) {
159 return creator->packet_.path_id; 159 return creator->packet_.path_id;
160 } 160 }
161 161
162 } // namespace test 162 } // namespace test
163 } // namespace net 163 } // namespace net
OLDNEW
« no previous file with comments | « net/quic/test_tools/mock_crypto_client_stream.cc ('k') | net/quic/test_tools/quic_test_utils.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698