The stream garbage collector loop in ossl_quic_stream_map_gc() is never entered

Also remove ready_for_gc_next(), it is not needed any more.

Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Norbert Pocs <norbertp@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/29402)
This commit is contained in:
Alexandr Nedvedicky
2025-12-16 11:01:43 +01:00
committed by Norbert Pocs
parent e547988940
commit 5a45547c8e

View File

@@ -67,8 +67,6 @@ static QUIC_STREAM *list_next(QUIC_STREAM_LIST_NODE *l, QUIC_STREAM_LIST_NODE *n
offsetof(QUIC_STREAM, active_node))
#define accept_next(l, s) list_next((l), &(s)->accept_node, \
offsetof(QUIC_STREAM, accept_node))
#define ready_for_gc_next(l, s) list_next((l), &(s)->ready_for_gc_node, \
offsetof(QUIC_STREAM, ready_for_gc_node))
#define accept_head(l) list_next((l), (l), \
offsetof(QUIC_STREAM, accept_node))
#define ready_for_gc_head(l) list_next((l), (l), \
@@ -806,13 +804,9 @@ size_t ossl_quic_stream_map_get_total_accept_queue_len(QUIC_STREAM_MAP *qsm)
void ossl_quic_stream_map_gc(QUIC_STREAM_MAP *qsm)
{
QUIC_STREAM *qs, *qs_head, *qsn = NULL;
for (qs = qs_head = ready_for_gc_head(&qsm->ready_for_gc_list);
qs != NULL && qs != qs_head;
qs = qsn) {
qsn = ready_for_gc_next(&qsm->ready_for_gc_list, qs);
QUIC_STREAM *qs;
while ((qs = ready_for_gc_head(&qsm->ready_for_gc_list)) != NULL) {
ossl_quic_stream_map_release(qsm, qs);
}
}