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

Unified Diff: net/quic/quic_sent_packet_manager.cc

Issue 968233004: Land Recent QUIC Changes until 03/02/2015. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@cleanup
Patch Set: Created 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/quic/quic_sent_packet_manager.h ('k') | net/quic/quic_server_id.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/quic/quic_sent_packet_manager.cc
diff --git a/net/quic/quic_sent_packet_manager.cc b/net/quic/quic_sent_packet_manager.cc
index 9c502f4d3e318e37f97394951e0918143d2c44d7..242d8e748ec3000eccb68939c2358df1ed36a46d 100644
--- a/net/quic/quic_sent_packet_manager.cc
+++ b/net/quic/quic_sent_packet_manager.cc
@@ -435,16 +435,14 @@ QuicSentPacketManager::PendingRetransmission
TransmissionType transmission_type = pending_retransmissions_.begin()->second;
if (unacked_packets_.HasPendingCryptoPackets()) {
// Ensure crypto packets are retransmitted before other packets.
- PendingRetransmissionMap::const_iterator it =
- pending_retransmissions_.begin();
- do {
- if (HasCryptoHandshake(unacked_packets_.GetTransmissionInfo(it->first))) {
- sequence_number = it->first;
- transmission_type = it->second;
+ for (const auto& pair : pending_retransmissions_) {
+ if (HasCryptoHandshake(
+ unacked_packets_.GetTransmissionInfo(pair.first))) {
+ sequence_number = pair.first;
+ transmission_type = pair.second;
break;
}
- ++it;
- } while (it != pending_retransmissions_.end());
+ }
}
DCHECK(unacked_packets_.IsUnacked(sequence_number)) << sequence_number;
const TransmissionInfo& transmission_info =
« no previous file with comments | « net/quic/quic_sent_packet_manager.h ('k') | net/quic/quic_server_id.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698