diff --git a/include/haproxy/server-t.h b/include/haproxy/server-t.h index dc238ec25..91ce6f37c 100644 --- a/include/haproxy/server-t.h +++ b/include/haproxy/server-t.h @@ -478,6 +478,9 @@ struct server { char *alpn_str; /* ALPN protocol string */ int alpn_len; /* ALPN protocol string length */ } ssl_ctx; +#ifdef USE_QUIC + struct quic_transport_params quic_params; /* QUIC transport parameters */ +#endif struct resolv_srvrq *srvrq; /* Pointer representing the DNS SRV requeest, if any */ struct list srv_rec_item; /* to attach server to a srv record item */ struct list ip_rec_item; /* to attach server to a A or AAAA record item */ diff --git a/src/server.c b/src/server.c index 4d7d1f0d8..39d798ec4 100644 --- a/src/server.c +++ b/src/server.c @@ -37,6 +37,7 @@ #include #include #include +#include #include #include #include @@ -3589,6 +3590,7 @@ static int _srv_parse_init(struct server **srv, char **args, int *cur_arg, (parse_flags & SRV_PARSE_INITIAL_RESOLVE ? PA_O_RESOLVE : 0) | PA_O_PORT_OK | (parse_flags & SRV_PARSE_IN_PEER_SECTION ? PA_O_PORT_MAND : PA_O_PORT_OFS) | PA_O_STREAM | PA_O_DGRAM | PA_O_XPRT); + if (!sk) { ha_alert("%s\n", errmsg); err_code |= ERR_ALERT | ERR_FATAL; @@ -3605,6 +3607,9 @@ static int _srv_parse_init(struct server **srv, char **args, int *cur_arg, err_code |= ERR_ALERT | ERR_FATAL; goto out; } + + newsrv->xprt = xprt_get(XPRT_QUIC); + quic_transport_params_init(&newsrv->quic_params, 0); } #endif