mirror of
https://gitea.invidious.io/iv-org/litespeed-quic.git
synced 2024-08-15 00:53:43 +00:00
Support new lsquic_stream_if callback on_conncloseframe_received() to notify application of CONNECTION_CLOSE frame
This commit is contained in:
parent
71eb4000ac
commit
123f116488
3 changed files with 16 additions and 0 deletions
|
@ -2098,6 +2098,9 @@ process_connection_close_frame (struct full_conn *conn, lsquic_packet_in_t *pack
|
|||
(int) reason_len, (const char *) p + reason_off);
|
||||
LSQ_INFO("Received CONNECTION_CLOSE frame (code: %"PRIu64"; reason: %.*s)",
|
||||
error_code, (int) reason_len, (const char *) p + reason_off);
|
||||
if (conn->fc_stream_ifs[STREAM_IF_STD].stream_if->on_conncloseframe_received)
|
||||
conn->fc_stream_ifs[STREAM_IF_STD].stream_if->on_conncloseframe_received(
|
||||
&conn->fc_conn, -1, error_code, (const char *) p + reason_off, reason_len);
|
||||
conn->fc_flags |= FC_RECV_CLOSE;
|
||||
if (!(conn->fc_flags & FC_CLOSING))
|
||||
{
|
||||
|
|
|
@ -5960,6 +5960,9 @@ process_connection_close_frame (struct ietf_full_conn *conn,
|
|||
LSQ_INFO("Received CONNECTION_CLOSE frame (%s-level code: %"PRIu64"; "
|
||||
"reason: %.*s)", app_error ? "application" : "transport",
|
||||
error_code, (int) reason_len, (const char *) p + reason_off);
|
||||
if (conn->ifc_enpub->enp_stream_if->on_conncloseframe_received)
|
||||
conn->ifc_enpub->enp_stream_if->on_conncloseframe_received(
|
||||
&conn->ifc_conn, app_error, error_code, (const char *) p + reason_off, reason_len);
|
||||
conn->ifc_flags |= IFC_RECV_CLOSE;
|
||||
if (!(conn->ifc_flags & IFC_CLOSING))
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue