summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorHugo Landau <hlandau@openssl.org>2023-04-18 19:30:55 +0100
committerHugo Landau <hlandau@openssl.org>2023-05-12 14:47:12 +0100
commite8b9f63235e82403b7e144ff9a1a3985d44f1c4e (patch)
treef218c0f4dda80478456240ccedcdd48e10733aa6 /include
parent723cbe8a73fe3644bb4d8f20d475e57f44955b54 (diff)
downloadopenssl-new-e8b9f63235e82403b7e144ff9a1a3985d44f1c4e.tar.gz
QUIC QSM: Clean up SEND_STREAM/RECV_STREAM handling
Reviewed-by: Matt Caswell <matt@openssl.org> Reviewed-by: Tomas Mraz <tomas@openssl.org> (Merged from https://github.com/openssl/openssl/pull/20765)
Diffstat (limited to 'include')
-rw-r--r--include/internal/quic_stream_map.h32
1 files changed, 17 insertions, 15 deletions
diff --git a/include/internal/quic_stream_map.h b/include/internal/quic_stream_map.h
index 2be73286ea..51e175ffb8 100644
--- a/include/internal/quic_stream_map.h
+++ b/include/internal/quic_stream_map.h
@@ -107,18 +107,6 @@ struct quic_stream_st {
unsigned int deleted : 1;
};
-/*
- * Marks a stream for STOP_SENDING. aec is the application error code (AEC).
- * This can only fail if it has already been called.
- */
-int ossl_quic_stream_stop_sending(QUIC_STREAM *s, uint64_t aec);
-
-/*
- * Marks a stream for reset. aec is the application error code (AEC).
- * This can only fail if it has already been called.
- */
-int ossl_quic_stream_reset(QUIC_STREAM *s, uint64_t aec);
-
/*
* QUIC Stream Map
* ===============
@@ -239,10 +227,24 @@ void ossl_quic_stream_map_set_rr_stepping(QUIC_STREAM_MAP *qsm, size_t stepping)
/*
* Resets the sending part of a stream.
+ *
+ * Returns 1 if the sending part of a stream was not already reset.
+ * Returns 0 otherwise, which need not be considered an error.
+ */
+int ossl_quic_stream_map_reset_stream_send_part(QUIC_STREAM_MAP *qsm,
+ QUIC_STREAM *qs,
+ uint64_t aec);
+
+/*
+ * Marks the receiving part of a stream for STOP_SENDING.
+ *
+ * Returns 1 if the receiving part of a stream was not already marked for
+ * STOP_SENDING.
+ * Returns 0 otherwise, which need not be considered an error.
*/
-void ossl_quic_stream_map_reset_stream_send_part(QUIC_STREAM_MAP *qsm,
- QUIC_STREAM *qs,
- uint64_t aec);
+int ossl_quic_stream_map_stop_sending_recv_part(QUIC_STREAM_MAP *qsm,
+ QUIC_STREAM *qs,
+ uint64_t aec);
/*
* Adds a stream to the accept queue.