| OLD | NEW |
| 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 #ifndef NET_QUIC_CORE_QUIC_PACKETS_H_ | 5 #ifndef NET_QUIC_CORE_QUIC_PACKETS_H_ |
| 6 #define NET_QUIC_CORE_QUIC_PACKETS_H_ | 6 #define NET_QUIC_CORE_QUIC_PACKETS_H_ |
| 7 | 7 |
| 8 #include <cstdint> | 8 #include <cstdint> |
| 9 #include <limits> | 9 #include <limits> |
| 10 #include <list> | 10 #include <list> |
| (...skipping 224 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 235 // 0: no padding | 235 // 0: no padding |
| 236 // otherwise: only pad up to num_padding_bytes bytes | 236 // otherwise: only pad up to num_padding_bytes bytes |
| 237 int16_t num_padding_bytes; | 237 int16_t num_padding_bytes; |
| 238 QuicPathId path_id; | 238 QuicPathId path_id; |
| 239 QuicPacketNumber packet_number; | 239 QuicPacketNumber packet_number; |
| 240 QuicPacketNumberLength packet_number_length; | 240 QuicPacketNumberLength packet_number_length; |
| 241 EncryptionLevel encryption_level; | 241 EncryptionLevel encryption_level; |
| 242 bool has_ack; | 242 bool has_ack; |
| 243 bool has_stop_waiting; | 243 bool has_stop_waiting; |
| 244 TransmissionType transmission_type; | 244 TransmissionType transmission_type; |
| 245 QuicPathId original_path_id; | |
| 246 QuicPacketNumber original_packet_number; | 245 QuicPacketNumber original_packet_number; |
| 247 | 246 |
| 248 // Optional notifiers which will be informed when this packet has been ACKed. | 247 // Optional notifiers which will be informed when this packet has been ACKed. |
| 249 std::list<AckListenerWrapper> listeners; | 248 std::list<AckListenerWrapper> listeners; |
| 250 }; | 249 }; |
| 251 | 250 |
| 252 // Deletes and clears all the frames and the packet from serialized packet. | 251 // Deletes and clears all the frames and the packet from serialized packet. |
| 253 QUIC_EXPORT_PRIVATE void ClearSerializedPacket( | 252 QUIC_EXPORT_PRIVATE void ClearSerializedPacket( |
| 254 SerializedPacket* serialized_packet); | 253 SerializedPacket* serialized_packet); |
| 255 | 254 |
| 256 // Allocates a new char[] of size |packet.encrypted_length| and copies in | 255 // Allocates a new char[] of size |packet.encrypted_length| and copies in |
| 257 // |packet.encrypted_buffer|. | 256 // |packet.encrypted_buffer|. |
| 258 QUIC_EXPORT_PRIVATE char* CopyBuffer(const SerializedPacket& packet); | 257 QUIC_EXPORT_PRIVATE char* CopyBuffer(const SerializedPacket& packet); |
| 259 | 258 |
| 260 } // namespace net | 259 } // namespace net |
| 261 | 260 |
| 262 #endif // NET_QUIC_CORE_QUIC_PACKETS_H_ | 261 #endif // NET_QUIC_CORE_QUIC_PACKETS_H_ |
| OLD | NEW |