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

Side by Side Diff: net/quic/quic_packet_creator.cc

Issue 14816006: Land Recent QUIC changes (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Added missing NET_PRIVATE_EXPORT to QuicWallTime Created 7 years, 7 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 | Annotate | Revision Log
« no previous file with comments | « net/quic/quic_packet_creator.h ('k') | net/quic/quic_packet_creator_test.cc » ('j') | 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/quic/quic_packet_creator.h" 5 #include "net/quic/quic_packet_creator.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "net/quic/crypto/quic_random.h" 8 #include "net/quic/crypto/quic_random.h"
9 #include "net/quic/quic_fec_group.h" 9 #include "net/quic/quic_fec_group.h"
10 #include "net/quic/quic_utils.h" 10 #include "net/quic/quic_utils.h"
(...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after
170 } 170 }
171 171
172 SerializedPacket QuicPacketCreator::SerializeConnectionClose( 172 SerializedPacket QuicPacketCreator::SerializeConnectionClose(
173 QuicConnectionCloseFrame* close_frame) { 173 QuicConnectionCloseFrame* close_frame) {
174 QuicFrames frames; 174 QuicFrames frames;
175 frames.push_back(QuicFrame(close_frame)); 175 frames.push_back(QuicFrame(close_frame));
176 return SerializeAllFrames(frames); 176 return SerializeAllFrames(frames);
177 } 177 }
178 178
179 QuicEncryptedPacket* QuicPacketCreator::SerializeVersionNegotiationPacket( 179 QuicEncryptedPacket* QuicPacketCreator::SerializeVersionNegotiationPacket(
180 const QuicVersionTagList& supported_versions) { 180 const QuicTagVector& supported_versions) {
181 DCHECK(is_server_); 181 DCHECK(is_server_);
182 QuicPacketPublicHeader header; 182 QuicPacketPublicHeader header;
183 header.guid = guid_; 183 header.guid = guid_;
184 header.reset_flag = false; 184 header.reset_flag = false;
185 header.version_flag = true; 185 header.version_flag = true;
186 header.versions = supported_versions; 186 header.versions = supported_versions;
187 QuicEncryptedPacket* encrypted = 187 QuicEncryptedPacket* encrypted =
188 framer_->ConstructVersionNegotiationPacket(header, supported_versions); 188 framer_->ConstructVersionNegotiationPacket(header, supported_versions);
189 DCHECK(encrypted); 189 DCHECK(encrypted);
190 DCHECK_GE(options_.max_packet_length, encrypted->length()); 190 DCHECK_GE(options_.max_packet_length, encrypted->length());
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
236 queued_frames_.push_back( 236 queued_frames_.push_back(
237 queued_retransmittable_frames_->AddNonStreamFrame(frame)); 237 queued_retransmittable_frames_->AddNonStreamFrame(frame));
238 } 238 }
239 } else { 239 } else {
240 queued_frames_.push_back(frame); 240 queued_frames_.push_back(frame);
241 } 241 }
242 return true; 242 return true;
243 } 243 }
244 244
245 } // namespace net 245 } // namespace net
OLDNEW
« no previous file with comments | « net/quic/quic_packet_creator.h ('k') | net/quic/quic_packet_creator_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698