From 366520020cd463db8fa8ecb600feedcbb1d91456 Mon Sep 17 00:00:00 2001 From: Benjamin Saunders Date: Tue, 2 Nov 2021 19:49:30 -0700 Subject: [PATCH] Style tweak --- quinn-proto/src/congestion/cubic.rs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/quinn-proto/src/congestion/cubic.rs b/quinn-proto/src/congestion/cubic.rs index 8edcded01..c3ce198ac 100644 --- a/quinn-proto/src/congestion/cubic.rs +++ b/quinn-proto/src/congestion/cubic.rs @@ -186,8 +186,10 @@ impl Controller for Cubic { self.cubic_state.w_max = self.window as f64; } - self.ssthresh = (self.cubic_state.w_max * BETA_CUBIC) as u64; - self.ssthresh = cmp::max(self.ssthresh, self.config.minimum_window); + self.ssthresh = cmp::max( + (self.cubic_state.w_max * BETA_CUBIC) as u64, + self.config.minimum_window, + ); self.window = self.ssthresh; self.cubic_state.k = self.cubic_state.cubic_k(self.config.max_datagram_size);