| Index: net/quic/quic_unacked_packet_map.cc
|
| diff --git a/net/quic/quic_unacked_packet_map.cc b/net/quic/quic_unacked_packet_map.cc
|
| index 7276b139e91bc7f223c40504c98187819a2c93a4..85074dfce46012056fbb193038c85b312fdd3682 100644
|
| --- a/net/quic/quic_unacked_packet_map.cc
|
| +++ b/net/quic/quic_unacked_packet_map.cc
|
| @@ -52,7 +52,7 @@ void QuicUnackedPacketMap::AddPacket(
|
|
|
| void QuicUnackedPacketMap::RemoveObsoletePackets() {
|
| while (!unacked_packets_.empty()) {
|
| - if (!IsPacketUseless(least_unacked_, unacked_packets_.front())) {
|
| + if (!IsPacketRemovable(least_unacked_, unacked_packets_.front())) {
|
| break;
|
| }
|
| delete unacked_packets_.front().all_transmissions;
|
| @@ -207,6 +207,16 @@ bool QuicUnackedPacketMap::IsPacketUseless(
|
| info.all_transmissions == NULL;
|
| }
|
|
|
| +bool QuicUnackedPacketMap::IsPacketRemovable(
|
| + QuicPacketSequenceNumber sequence_number,
|
| + const TransmissionInfo& info) const {
|
| + return (sequence_number <= largest_observed_ ||
|
| + unacked_packets_.size() > kMaxTcpCongestionWindow) &&
|
| + !info.in_flight &&
|
| + info.retransmittable_frames == NULL &&
|
| + info.all_transmissions == NULL;
|
| +}
|
| +
|
| bool QuicUnackedPacketMap::IsUnacked(
|
| QuicPacketSequenceNumber sequence_number) const {
|
| if (sequence_number < least_unacked_ ||
|
|
|