]> git.ipfire.org Git - thirdparty/openssl.git/commitdiff
QUIC RXFC: Don't emit a MAX_STREAM_DATA frame if we have a final size
authorHugo Landau <hlandau@openssl.org>
Mon, 31 Oct 2022 15:22:45 +0000 (15:22 +0000)
committerHugo Landau <hlandau@openssl.org>
Fri, 13 Jan 2023 13:20:11 +0000 (13:20 +0000)
Reviewed-by: Tomas Mraz <tomas@openssl.org>
Reviewed-by: Matt Caswell <matt@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/19703)

ssl/quic/quic_fc.c

index 84a3753a81020acb310a624ba2c95a1eae52fead..40bdd9909f2f793ae2110b56adde84887e367c49 100644 (file)
@@ -230,7 +230,11 @@ static int rxfc_cwm_bump_desired(QUIC_RXFC *rxfc)
          */
         threshold = rxfc->cur_window_size / 2;
 
-    return window_rem <= threshold;
+    /*
+     * No point emitting a new MAX_STREAM_DATA frame if the stream has a final
+     * size.
+     */
+    return !rxfc->is_fin && window_rem <= threshold;
 }
 
 static int rxfc_should_bump_window_size(QUIC_RXFC *rxfc, OSSL_TIME rtt)