From: Amaury Denoyelle Date: Fri, 1 Jul 2022 14:11:03 +0000 (+0200) Subject: MINOR: mux-quic: rename qcs flag FIN_RECV to SIZE_KNOWN X-Git-Tag: v2.7-dev2~100 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=3f39b40fe0086e6c4464ec9db6b84a6ba97b350e;p=thirdparty%2Fhaproxy.git MINOR: mux-quic: rename qcs flag FIN_RECV to SIZE_KNOWN Rename QC_SF_FIN_RECV to the more generic name QC_SF_SIZE_KNOWN. This better align with the QUIC RFC 9000 which uses the "Size Known" state definition. This change is purely cosmetic. --- diff --git a/include/haproxy/mux_quic-t.h b/include/haproxy/mux_quic-t.h index 168f074443..a2004a49c7 100644 --- a/include/haproxy/mux_quic-t.h +++ b/include/haproxy/mux_quic-t.h @@ -100,7 +100,7 @@ struct qcc { }; #define QC_SF_NONE 0x00000000 -#define QC_SF_FIN_RECV 0x00000001 /* last frame received for this stream */ +#define QC_SF_SIZE_KNOWN 0x00000001 /* last frame received for this stream */ #define QC_SF_FIN_STREAM 0x00000002 /* FIN bit must be set for last frame of the stream */ #define QC_SF_BLK_MROOM 0x00000004 /* app layer is blocked waiting for room in the qcs.tx.buf */ #define QC_SF_DETACH 0x00000008 /* sc is detached but there is remaining data to send */ diff --git a/src/mux_quic.c b/src/mux_quic.c index 24c7373ba6..ccdcf54c61 100644 --- a/src/mux_quic.c +++ b/src/mux_quic.c @@ -541,7 +541,7 @@ static int qcc_decode_qcs(struct qcc *qcc, struct qcs *qcs) /* Signal FIN to application if STREAM FIN received and there is no gap * in the Rx buffer. */ - if (qcs->flags & QC_SF_FIN_RECV && !ncb_is_fragmented(&qcs->rx.ncbuf)) + if (qcs->flags & QC_SF_SIZE_KNOWN && !ncb_is_fragmented(&qcs->rx.ncbuf)) fin = 1; ret = qcc->app_ops->decode_qcs(qcs, &b, fin); @@ -672,7 +672,7 @@ int qcc_recv(struct qcc *qcc, uint64_t id, uint64_t len, uint64_t offset, } if (fin) - qcs->flags |= QC_SF_FIN_RECV; + qcs->flags |= QC_SF_SIZE_KNOWN; if (ncb_data(&qcs->rx.ncbuf, 0) && !(qcs->flags & QC_SF_DEM_FULL)) qcc_decode_qcs(qcc, qcs);