From: Amaury Denoyelle Date: Fri, 3 Dec 2021 13:38:31 +0000 (+0100) Subject: MEDIUM: mux-quic: subscribe on xprt if remaining data after send X-Git-Tag: v2.6-dev1~315 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a2c58a7c8da549da007f51a7e2106ce35b445b5a;p=thirdparty%2Fhaproxy.git MEDIUM: mux-quic: subscribe on xprt if remaining data after send The streams data are transferred from the qcs.buf to the qcs.xprt_buf during qc_send. If the xprt_buf is not empty and not all data can be transferred, subscribe the connection on the xprt for sending. The mux will be woken up by the xprt when the xprt_buf will be cleared. This happens on ACK reception. --- diff --git a/src/mux_quic.c b/src/mux_quic.c index 3b194f687f..1f49e010c8 100644 --- a/src/mux_quic.c +++ b/src/mux_quic.c @@ -197,6 +197,11 @@ static int qc_send(struct qcc *qcc) fprintf(stderr, "%s ret=%d\n", __func__, ret); qcs->tx.offset += ret; + + if (b_data(buf)) { + qcc->conn->xprt->subscribe(qcc->conn, qcc->conn->xprt_ctx, + SUB_RETRY_SEND, &qcc->wait_event); + } } node = eb64_next(node); }