From d169efe52bdfa56955a73689f110fffba35c3424 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20L=C3=A9caille?= Date: Fri, 5 Nov 2021 11:40:50 +0100 Subject: [PATCH] MINOR: quic_sock: missing CO_FL_ADDR_TO_SET flag When allocating destination addresses for QUIC connections we did not set this flag which denotes these addresses have been set. This had as side effect to prevent the H3 request results from being returned to the QUIC clients. Note that this bug was revealed by this commit: "MEDIUM: backend: Rely on addresses at stream level to init server connection" Thanks to Christopher for having found the real cause of this issue. --- src/quic_sock.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/quic_sock.c b/src/quic_sock.c index bb6cb6150..a574de0c0 100644 --- a/src/quic_sock.c +++ b/src/quic_sock.c @@ -92,19 +92,17 @@ static int new_quic_cli_conn(struct quic_conn *qc, struct listener *l, struct sockaddr_storage *saddr) { struct connection *cli_conn; - struct sockaddr_storage *dst; - dst = NULL; if (unlikely((cli_conn = conn_new(&l->obj_type)) == NULL)) goto out; - if (!sockaddr_alloc(&dst, saddr, sizeof *saddr)) + if (!sockaddr_alloc(&cli_conn->dst, saddr, sizeof *saddr)) goto out_free_conn; + cli_conn->flags |= CO_FL_ADDR_TO_SET; qc->conn = cli_conn; cli_conn->qc = qc; - cli_conn->dst = dst; cli_conn->handle.fd = l->rx.fd; cli_conn->target = &l->obj_type;