Skip to content

Commit

Permalink
Fix handling restart from idle for bbr/bbr3 algorithms
Browse files Browse the repository at this point in the history
  • Loading branch information
iyangsj committed May 15, 2024
1 parent 8e0df9a commit 102477b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/congestion_control/bbr.rs
Original file line number Diff line number Diff line change
Expand Up @@ -921,8 +921,8 @@ impl CongestionController for Bbr {
self.stats.bytes_lost_in_total,
);

self.stats.bytes_in_flight += packet.sent_size as u64;
self.handle_restart_from_idle(self.stats.bytes_in_flight);
self.stats.bytes_in_flight += packet.sent_size as u64;
}

fn begin_ack(&mut self, now: Instant, bytes_in_flight: u64) {
Expand Down
2 changes: 1 addition & 1 deletion src/congestion_control/bbr3.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1850,8 +1850,8 @@ impl CongestionController for Bbr3 {
self.stats.bytes_lost_in_total,
);

self.stats.bytes_in_flight += packet.sent_size as u64;
self.handle_restart_from_idle(now, self.stats.bytes_in_flight);
self.stats.bytes_in_flight += packet.sent_size as u64;
}

fn begin_ack(&mut self, now: Instant, bytes_in_flight: u64) {
Expand Down

0 comments on commit 102477b

Please sign in to comment.