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

Side by Side Diff: net/quic/core/quic_protocol.cc

Issue 2509053004: Move some more constants and typedefs around. No behavior change. (Closed)
Patch Set: Created 4 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/quic/core/quic_protocol.h ('k') | net/quic/core/quic_types.h » ('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/core/quic_protocol.h" 5 #include "net/quic/core/quic_protocol.h"
6 6
7 #include "base/memory/ptr_util.h" 7 #include "base/memory/ptr_util.h"
8 #include "base/strings/string_number_conversions.h" 8 #include "base/strings/string_number_conversions.h"
9 #include "net/quic/core/quic_flags.h" 9 #include "net/quic/core/quic_flags.h"
10 #include "net/quic/core/quic_utils.h" 10 #include "net/quic/core/quic_utils.h"
11 #include "net/quic/core/quic_versions.h" 11 #include "net/quic/core/quic_versions.h"
12 12
13 using base::StringPiece; 13 using base::StringPiece;
14 using std::map; 14 using std::map;
15 using std::numeric_limits; 15 using std::numeric_limits;
16 using std::ostream; 16 using std::ostream;
17 using std::string; 17 using std::string;
18 18
19 namespace net { 19 namespace net {
20 20
21 const char* const kFinalOffsetHeaderKey = ":final-offset";
22
23 size_t GetPacketHeaderSize(QuicVersion version, 21 size_t GetPacketHeaderSize(QuicVersion version,
24 const QuicPacketHeader& header) { 22 const QuicPacketHeader& header) {
25 return GetPacketHeaderSize(version, header.public_header.connection_id_length, 23 return GetPacketHeaderSize(version, header.public_header.connection_id_length,
26 header.public_header.version_flag, 24 header.public_header.version_flag,
27 header.public_header.multipath_flag, 25 header.public_header.multipath_flag,
28 header.public_header.nonce != nullptr, 26 header.public_header.nonce != nullptr,
29 header.public_header.packet_number_length); 27 header.public_header.packet_number_length);
30 } 28 }
31 29
32 size_t GetPacketHeaderSize(QuicVersion version, 30 size_t GetPacketHeaderSize(QuicVersion version,
(...skipping 708 matching lines...) Expand 10 before | Expand all | Expand 10 after
741 is_unackable(false), 739 is_unackable(false),
742 has_crypto_handshake(has_crypto_handshake), 740 has_crypto_handshake(has_crypto_handshake),
743 num_padding_bytes(num_padding_bytes), 741 num_padding_bytes(num_padding_bytes),
744 retransmission(0) {} 742 retransmission(0) {}
745 743
746 TransmissionInfo::TransmissionInfo(const TransmissionInfo& other) = default; 744 TransmissionInfo::TransmissionInfo(const TransmissionInfo& other) = default;
747 745
748 TransmissionInfo::~TransmissionInfo() {} 746 TransmissionInfo::~TransmissionInfo() {}
749 747
750 } // namespace net 748 } // namespace net
OLDNEW
« no previous file with comments | « net/quic/core/quic_protocol.h ('k') | net/quic/core/quic_types.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698