Skip to content

Commit

Permalink
Update draft-ietf-quic-recovery.md
Browse files Browse the repository at this point in the history
  • Loading branch information
ianswett committed Dec 10, 2020
1 parent e31cea2 commit a8acd4f
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions draft-ietf-quic-recovery.md
Original file line number Diff line number Diff line change
Expand Up @@ -1811,16 +1811,16 @@ Invoked when DetectAndRemoveLostPackets deems packets lost.

~~~
OnPacketsLost(lost_packets):
latest_time_of_in_flight_lost = 0
time_of_latest_in_flight_loss = 0
// Remove lost packets from bytes_in_flight.
for lost_packet in lost_packets:
if lost_packet.in_flight:
bytes_in_flight -= lost_packet.sent_bytes
latest_time_of_in_flight_lost =
max(latest_time_of_in_flight_lost, lost_packet.time_sent)
time_of_latest_in_flight_loss =
max(time_of_latest_in_flight_loss, lost_packet.time_sent)
// Congestion event if in-flight packets were lost
if (latest_time_of_in_flight_lost != 0):
OnCongestionEvent(latest_time_of_in_flight_lost)
if (time_of_latest_in_flight_loss != 0):
OnCongestionEvent(time_of_latest_in_flight_loss)

// Reset the congestion window if the loss of these
// packets indicates persistent congestion.
Expand Down

0 comments on commit a8acd4f

Please sign in to comment.