From 6697e87ae5e1f569dc87cf690b5ecfc049c4aab0 Mon Sep 17 00:00:00 2001 From: Christopher Faulet Date: Tue, 4 Jun 2024 19:01:18 +0200 Subject: [PATCH] MINOR: mux-quic: Don't send an emtpy H3 DATA frame during zero-copy forwarding It may only happens when there is no data to forward but a last stream frame must be sent with the FIN bit. It is not invalid, but it is useless to send an empty H3 DATA frame in that case. --- src/mux_quic.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/mux_quic.c b/src/mux_quic.c index 8272b93da76b9..97cfb27ce0ba2 100644 --- a/src/mux_quic.c +++ b/src/mux_quic.c @@ -3058,7 +3058,8 @@ static size_t qmux_strm_done_ff(struct stconn *sc) goto end; } - data += sd->iobuf.offset; + if (data) + data += sd->iobuf.offset; total = qcs->qcc->app_ops->done_ff(qcs); if (data || qcs->flags & QC_SF_FIN_STREAM)