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

Unified Diff: net/quic/quic_ack_notifier.cc

Issue 908623002: Revert of Landing Recent QUIC Changes. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
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_ack_notifier.h ('k') | net/quic/quic_ack_notifier_manager.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/quic/quic_ack_notifier.cc
diff --git a/net/quic/quic_ack_notifier.cc b/net/quic/quic_ack_notifier.cc
index 48ee23df1a45bac5c7ce4876489feb930fabfc36..b399a61bcc173541f22d65d49fe653caa6baa023 100644
--- a/net/quic/quic_ack_notifier.cc
+++ b/net/quic/quic_ack_notifier.cc
@@ -29,18 +29,21 @@
QuicAckNotifier::~QuicAckNotifier() {
}
-void QuicAckNotifier::OnSerializedPacket() {
+void QuicAckNotifier::AddSequenceNumber(
+ const QuicPacketSequenceNumber& sequence_number,
+ int packet_payload_size) {
++unacked_packets_;
+ DVLOG(1) << "AckNotifier waiting for packet: " << sequence_number;
}
-bool QuicAckNotifier::OnAck(QuicTime::Delta delta_largest_observed) {
+bool QuicAckNotifier::OnAck(QuicPacketSequenceNumber sequence_number,
+ QuicTime::Delta delta_largest_observed) {
if (unacked_packets_ <= 0) {
- LOG(DFATAL) << "Acked more packets than were tracked."
- << " unacked_packets:" << unacked_packets_;
+ LOG(DFATAL) << "Acked more packets than were tracked.";
return true;
}
--unacked_packets_;
- if (!HasUnackedPackets()) {
+ if (IsEmpty()) {
// We have seen all the sequence numbers we were waiting for, trigger
// callback notification.
delegate_->OnAckNotification(retransmitted_packet_count_,
@@ -51,16 +54,6 @@
return false;
}
-bool QuicAckNotifier::OnPacketAbandoned() {
- if (unacked_packets_ <= 0) {
- LOG(DFATAL) << "Abandoned more packets than were tracked."
- << " unacked_packets:" << unacked_packets_;
- return true;
- }
- --unacked_packets_;
- return unacked_packets_ == 0;
-}
-
void QuicAckNotifier::OnPacketRetransmitted(int packet_payload_size) {
++retransmitted_packet_count_;
retransmitted_byte_count_ += packet_payload_size;
« no previous file with comments | « net/quic/quic_ack_notifier.h ('k') | net/quic/quic_ack_notifier_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698