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

Unified Diff: net/quic/quic_utils.cc

Issue 1666553002: Make QUIC's SerializedPacket contain QuicFrames, rather than a pointer (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@113205205
Patch Set: Created 4 years, 11 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/quic_unacked_packet_map_test.cc ('k') | net/quic/test_tools/quic_packet_creator_peer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/quic/quic_utils.cc
diff --git a/net/quic/quic_utils.cc b/net/quic/quic_utils.cc
index 2213f0bfa8ffb55e1314a6579aaffb061baf73a8..047cfe2387f87a72f326c9416e5f458b44e872e1 100644
--- a/net/quic/quic_utils.cc
+++ b/net/quic/quic_utils.cc
@@ -455,12 +455,10 @@ void QuicUtils::RemoveFramesForStream(QuicFrames* frames,
// static
void QuicUtils::ClearSerializedPacket(SerializedPacket* serialized_packet) {
- if (serialized_packet->retransmittable_frames != nullptr) {
- DeleteFrames(serialized_packet->retransmittable_frames);
+ if (!serialized_packet->retransmittable_frames.empty()) {
+ DeleteFrames(&serialized_packet->retransmittable_frames);
}
- delete serialized_packet->retransmittable_frames;
delete serialized_packet->packet;
- serialized_packet->retransmittable_frames = nullptr;
serialized_packet->packet = nullptr;
}
« no previous file with comments | « net/quic/quic_unacked_packet_map_test.cc ('k') | net/quic/test_tools/quic_packet_creator_peer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698