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

Unified Diff: net/quic/quic_sent_packet_manager.cc

Issue 473763004: Refactor QuicConnection's async write behavior to record a packet as (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@cleanup_release
Patch Set: Created 6 years, 4 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_connection_test.cc ('k') | net/quic/quic_stream_factory_test.cc » ('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 ffdea9bc449eba38e33bb3cfe8b945aead0bcd3e..41221ccee2dd25daf69556aff1df6b6a5b37b281 100644
--- a/net/quic/quic_sent_packet_manager.cc
+++ b/net/quic/quic_sent_packet_manager.cc
@@ -520,15 +520,11 @@ bool QuicSentPacketManager::OnPacketSent(
TransmissionType transmission_type,
HasRetransmittableData has_retransmittable_data) {
DCHECK_LT(0u, sequence_number);
+ DCHECK(unacked_packets_.IsUnacked(sequence_number));
LOG_IF(DFATAL, bytes == 0) << "Cannot send empty packets.";
if (pending_timer_transmission_count_ > 0) {
--pending_timer_transmission_count_;
}
- // In rare circumstances, the packet could be serialized, sent, and then acked
- // before OnPacketSent is called.
- if (!unacked_packets_.IsUnacked(sequence_number)) {
- return false;
- }
if (unacked_packets_.bytes_in_flight() == 0) {
// TODO(ianswett): Consider being less aggressive to force a new
« no previous file with comments | « net/quic/quic_connection_test.cc ('k') | net/quic/quic_stream_factory_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698