summaryrefslogtreecommitdiffstats
path: root/src/quic_conn.c
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/quic_conn.c18
1 files changed, 6 insertions, 12 deletions
diff --git a/src/quic_conn.c b/src/quic_conn.c
index 6cc1d38..9a3ce29 100644
--- a/src/quic_conn.c
+++ b/src/quic_conn.c
@@ -161,7 +161,9 @@ void qc_kill_conn(struct quic_conn *qc)
TRACE_PROTO("killing the connection", QUIC_EV_CONN_KILL, qc);
qc->flags |= QUIC_FL_CONN_TO_KILL;
qc->flags &= ~QUIC_FL_CONN_RETRANS_NEEDED;
- task_wakeup(qc->idle_timer_task, TASK_WOKEN_OTHER);
+
+ if (!(qc->flags & QUIC_FL_CONN_EXP_TIMER))
+ task_wakeup(qc->idle_timer_task, TASK_WOKEN_OTHER);
qc_notify_err(qc);
@@ -549,11 +551,8 @@ struct task *quic_conn_app_io_cb(struct task *t, void *context, unsigned int sta
{
struct list send_list = LIST_HEAD_INIT(send_list);
struct quic_conn *qc = context;
- struct quic_enc_level *qel;
TRACE_ENTER(QUIC_EV_CONN_IO_CB, qc);
-
- qel = qc->ael;
TRACE_STATE("connection handshake state", QUIC_EV_CONN_IO_CB, qc, &qc->state);
if (qc_test_fd(qc))
@@ -592,11 +591,10 @@ struct task *quic_conn_app_io_cb(struct task *t, void *context, unsigned int sta
goto out;
}
- if (!qel_need_sending(qel, qc))
- goto out;
-
/* XXX TODO: how to limit the list frames to send */
- qel_register_send(&send_list, qel, &qel->pktns->tx.frms);
+ if (qel_need_sending(qc->ael, qc))
+ qel_register_send(&send_list, qc->ael, &qc->ael->pktns->tx.frms);
+
if (!qc_send(qc, 0, &send_list)) {
TRACE_DEVEL("qc_send() failed", QUIC_EV_CONN_IO_CB, qc);
goto out;
@@ -802,10 +800,6 @@ struct task *quic_conn_io_cb(struct task *t, void *context, unsigned int state)
qel_register_send(&send_list, qel, &qel->pktns->tx.frms);
}
- /* Skip sending if no QEL with frames to sent. */
- if (LIST_ISEMPTY(&send_list))
- goto out;
-
if (!qc_send(qc, 0, &send_list)) {
TRACE_DEVEL("qc_send() failed", QUIC_EV_CONN_IO_CB, qc);
goto out;