From c6c0432cca9c46bde56a9480796762f25d2a18a7 Mon Sep 17 00:00:00 2001 From: Hugo Landau Date: Tue, 18 Apr 2023 19:30:54 +0100 Subject: QUIC CHANNEL: Remove stream 0-specific code Reviewed-by: Matt Caswell Reviewed-by: Tomas Mraz (Merged from https://github.com/openssl/openssl/pull/20765) --- ssl/quic/quic_channel.c | 25 ------------------------- ssl/quic/quic_channel_local.h | 6 ------ 2 files changed, 31 deletions(-) (limited to 'ssl') diff --git a/ssl/quic/quic_channel.c b/ssl/quic/quic_channel.c index bb693352e7..5d72ac82a3 100644 --- a/ssl/quic/quic_channel.c +++ b/ssl/quic/quic_channel.c @@ -225,26 +225,6 @@ static int ch_init(QUIC_CHANNEL *ch) goto err; } - if ((ch->stream0 = ossl_quic_stream_map_alloc(&ch->qsm, 0, - QUIC_STREAM_INITIATOR_CLIENT - | QUIC_STREAM_DIR_BIDI)) == NULL) - goto err; - - if ((ch->stream0->sstream = ossl_quic_sstream_new(INIT_APP_BUF_LEN)) == NULL) - goto err; - - if ((ch->stream0->rstream = ossl_quic_rstream_new(NULL, NULL, 0)) == NULL) - goto err; - - if (!ossl_quic_txfc_init(&ch->stream0->txfc, &ch->conn_txfc)) - goto err; - - if (!ossl_quic_rxfc_init(&ch->stream0->rxfc, &ch->conn_rxfc, - 1 * 1024 * 1024, - 5 * 1024 * 1024, - get_time, ch)) - goto err; - /* Plug in the TLS handshake layer. */ tls_args.s = ch->tls; tls_args.crypto_send_cb = ch_on_crypto_send; @@ -311,11 +291,6 @@ static void ch_cleanup(QUIC_CHANNEL *ch) ossl_statm_destroy(&ch->statm); ossl_ackm_free(ch->ackm); - if (ch->stream0 != NULL) { - assert(ch->have_qsm); - ossl_quic_stream_map_release(&ch->qsm, ch->stream0); /* frees sstream */ - } - if (ch->have_qsm) ossl_quic_stream_map_cleanup(&ch->qsm); diff --git a/ssl/quic/quic_channel_local.h b/ssl/quic/quic_channel_local.h index 1e9e0e1e68..555e6117d8 100644 --- a/ssl/quic/quic_channel_local.h +++ b/ssl/quic/quic_channel_local.h @@ -97,12 +97,6 @@ struct quic_channel_st { QUIC_SSTREAM *crypto_send[QUIC_PN_SPACE_NUM]; QUIC_RSTREAM *crypto_recv[QUIC_PN_SPACE_NUM]; - /* - * Our (currently only) application data stream. This is a bidirectional - * client-initiated stream and thus (in QUICv1) always has a stream ID of 0. - */ - QUIC_STREAM *stream0; - /* Internal state. */ /* * Client: The DCID used in the first Initial packet we transmit as a client. -- cgit v1.2.1