From dfb9fad1830dc9e4980beabb4dd75b577a9732ef Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20L=C3=A9caille?= Date: Tue, 11 Jul 2023 16:52:46 +0200 Subject: [PATCH] MINOR: quic: Add traces to qc_may_build_pkt() This patch is very useful to debug issues in relation with the packets building. --- src/quic_conn.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/quic_conn.c b/src/quic_conn.c index 2b3814976..891ea41f1 100644 --- a/src/quic_conn.c +++ b/src/quic_conn.c @@ -3441,6 +3441,11 @@ static int qc_may_build_pkt(struct quic_conn *qc, struct list *frms, ((qel->pktns->flags & QUIC_FL_PKTNS_ACK_REQUIRED) && (force_ack || nb_aepkts_since_last_ack >= QUIC_MAX_RX_AEPKTS_SINCE_LAST_ACK)); + TRACE_PRINTF(TRACE_LEVEL_DEVELOPER, QUIC_EV_CONN_PHPKTS, qc, 0, 0, 0, + "has_sec=%d cc=%d probe=%d must_ack=%d frms=%d prep_in_fligh=%llu cwnd=%llu", + quic_tls_has_tx_sec(qel), cc, probe, *must_ack, LIST_ISEMPTY(frms), + (ullong)qc->path->prep_in_flight, (ullong)qc->path->cwnd); + /* Do not build any more packet if the TX secrets are not available or * if there is nothing to send, i.e. if no CONNECTION_CLOSE or ACK are required * and if there is no more packets to send upon PTO expiration