From 0056454e38b13de295976a5e768b6d46507d8168 Mon Sep 17 00:00:00 2001 From: IWAMOTO Toshihiro Date: Fri, 28 Jul 2023 17:32:47 +0900 Subject: [PATCH] Correctly account for datagram queue in delivery_rate_check_if_app_limited Datagram byte size should be used instead of the number of packets. --- quiche/src/lib.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/quiche/src/lib.rs b/quiche/src/lib.rs index e9e1802192..ad1485bf93 100644 --- a/quiche/src/lib.rs +++ b/quiche/src/lib.rs @@ -7156,7 +7156,7 @@ impl Connection { .filter_map(|(_, p)| p.active().then(|| p.recovery.cwnd_available())) .sum(); - ((self.tx_buffered + self.dgram_send_queue_len()) < cwin_available) && + ((self.tx_buffered + self.dgram_send_queue_byte_size()) < cwin_available) && (self.tx_data.saturating_sub(self.last_tx_data)) < cwin_available as u64 && cwin_available > 0