Skip to content

Commit

Permalink
BUG/MINOR: quic: fix trace on releasing STREAM frame after ack
Browse files Browse the repository at this point in the history
Fix NULL argument pass to qc_release_frm(). This allows to give more
context on the traces inside it. Note that no crash occured as QUIC
traces always check validity on first arg before derefencing it.

No backport needed.
  • Loading branch information
a-denoyelle committed Oct 2, 2024
1 parent 58b7a72 commit b74df9f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/quic_stream.c
Original file line number Diff line number Diff line change
Expand Up @@ -178,6 +178,7 @@ static struct qc_stream_buf *qc_stream_buf_ack(struct qc_stream_buf *buf,
static void qc_stream_buf_consume(struct qc_stream_buf *stream_buf,
struct qc_stream_desc *stream)
{
struct quic_conn *qc = stream->qc;
struct eb64_node *frm_node;
struct qf_stream *strm_frm;
struct quic_frame *frm;
Expand All @@ -201,7 +202,7 @@ static void qc_stream_buf_consume(struct qc_stream_buf *stream_buf,
*/
eb64_delete(frm_node);
stream_buf = qc_stream_buf_ack(stream_buf, stream, offset, len, fin);
qc_release_frm(NULL, frm);
qc_release_frm(qc, frm);

frm_node = stream_buf ? eb64_first(&stream_buf->acked_frms) : NULL;
}
Expand Down

0 comments on commit b74df9f

Please sign in to comment.