Don't use a flow controller for QuicCryptoStream when it uses CRYPTO frames
gfe-relnote: QuicCryptoStream change protected behind QUIC_VERSION_99
PiperOrigin-RevId: 248004335
Change-Id: I97d5b6ed0e5523a4264ce2f06e5f6c3249a99fe9
diff --git a/quic/core/quic_crypto_stream.cc b/quic/core/quic_crypto_stream.cc
index 836fbac..2263546 100644
--- a/quic/core/quic_crypto_stream.cc
+++ b/quic/core/quic_crypto_stream.cc
@@ -28,7 +28,10 @@
session->connection()->transport_version()),
session,
/*is_static=*/true,
- BIDIRECTIONAL),
+ QuicVersionUsesCryptoFrames(
+ session->connection()->transport_version())
+ ? CRYPTO
+ : BIDIRECTIONAL),
substreams_{{this, ENCRYPTION_INITIAL},
{this, ENCRYPTION_HANDSHAKE},
{this, ENCRYPTION_ZERO_RTT},