quic: removing quicly_send call from quic_accept_connection
Type: fix
@@ -1854,9 +1854,12 @@ quic_accept_connection (u32 ctx_index, quic_rx_packet_ctx_t * pctx)
quic_proto_on_close (ctx_index, thread_index);
return rv;
}
- ctx->conn_state = QUIC_CONN_STATE_HANDSHAKE;
- return quic_send_packets (ctx);
+ ctx->conn_state = QUIC_CONN_STATE_READY;
+ pctx->ctx_index = ctx_index;
+ pctx->thread_index = thread_index;
+
+ return 0;
}
static int
@@ -2039,13 +2042,22 @@ rx_start:
}
for (i = 0; i < max_packets; i++)
{
- if (packets_ctx[i].ptype != QUIC_PACKET_TYPE_RECEIVE)
- continue;
+ switch (packets_ctx[i].ptype)
+ {
+ case QUIC_PACKET_TYPE_RECEIVE:
ctx = quic_ctx_get (packets_ctx[i].ctx_index,
packets_ctx[i].thread_index);
quic_check_quic_session_connected (ctx);
ctx = quic_ctx_get (packets_ctx[i].ctx_index,
packets_ctx[i].thread_index);
+ break;
+ case QUIC_PACKET_TYPE_ACCEPT:
+ ctx = quic_ctx_get (packets_ctx[i].ctx_index,
+ packets_ctx[i].thread_index);
+ break;
+ default:
+ continue;
+ }
quic_send_packets (ctx);
}
