]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
MINOR: quic-stream: add qc field
authorAmaury Denoyelle <adenoyelle@haproxy.com>
Thu, 21 Apr 2022 09:00:41 +0000 (11:00 +0200)
committerAmaury Denoyelle <adenoyelle@haproxy.com>
Thu, 21 Apr 2022 09:55:29 +0000 (11:55 +0200)
Add a new member <qc> in qc_stream_desc structure. This change is
possible since previous patch which add quic-conn argument to
qc_stream_desc_new().

The purpose of this change is to simplify the future evolution of
qc-stream-desc API. This will avoid to repeat qc as argument in various
functions which already used a qc_stream_desc.

include/haproxy/quic_stream-t.h
src/quic_stream.c

index ff88053b3dba9f544f635a0dfe902126060a4dfb..f1feb5c3d7e7817c4cc6ddda9a0e447f2772b99f 100644 (file)
@@ -18,6 +18,7 @@
  */
 struct qc_stream_desc {
        struct eb64_node by_id; /* node for quic_conn tree */
+       struct quic_conn *qc;
 
        struct buffer buf; /* buffer for STREAM data on Tx, emptied on acknowledge */
        uint64_t ack_offset; /* last acknowledged offset */
index 6bdd00dce4303ef2634e2831b4de468061d9a3fc..69fafbb34cffd561bf57ddf51cc7c2c08e048f7b 100644 (file)
@@ -28,6 +28,7 @@ struct qc_stream_desc *qc_stream_desc_new(uint64_t id, void *ctx,
 
        stream->by_id.key = id;
        eb64_insert(&qc->streams_by_id, &stream->by_id);
+       stream->qc = qc;
 
        stream->buf = BUF_NULL;
        stream->acked_frms = EB_ROOT;