mirror of
https://gitea.invidious.io/iv-org/litespeed-quic.git
synced 2024-08-15 00:53:43 +00:00
Fix gQUIC connection close: there is no HEADERS stream without HTTP flag
This is a bit of an unexpected use case, as gQUIC usually means that there is HEADERS stream, but the API allows one to turn HTTP off. Fixes bug #220.
This commit is contained in:
parent
65c5d50287
commit
50c35e5b80
1 changed files with 3 additions and 1 deletions
|
@ -2615,10 +2615,12 @@ maybe_close_conn (struct full_conn *conn)
|
|||
struct lsquic_stream *stream;
|
||||
struct lsquic_hash_elem *el;
|
||||
#endif
|
||||
const unsigned n_special_stream = N_SPECIAL_STREAMS
|
||||
- !(conn->fc_flags & FC_HTTP);
|
||||
|
||||
if ((conn->fc_flags & (FC_CLOSING|FC_GOAWAY_SENT|FC_SERVER))
|
||||
== (FC_GOAWAY_SENT|FC_SERVER)
|
||||
&& lsquic_hash_count(conn->fc_pub.all_streams) == N_SPECIAL_STREAMS)
|
||||
&& lsquic_hash_count(conn->fc_pub.all_streams) == n_special_streams)
|
||||
{
|
||||
#ifndef NDEBUG
|
||||
for (el = lsquic_hash_first(conn->fc_pub.all_streams); el;
|
||||
|
|
Loading…
Reference in a new issue