summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarlos Garcia Campos <cgarcia@igalia.com>2022-06-29 14:57:15 +0200
committerCarlos Garcia Campos <cgarcia@igalia.com>2022-06-30 10:27:51 +0200
commit7413504b5dc939be9f3dfa4ffa8fdd04dcac773f (patch)
tree0c5e4b2083718a10936d046a54af042ad322d475
parente17f6dd239503ecc61c28e34cdea915f9eda09bf (diff)
downloadlibsoup-7413504b5dc939be9f3dfa4ffa8fdd04dcac773f.tar.gz
http2: handle the case of last stream id being max int32 in goaway
This means it's a graceful goaway and we should not allow new requests, another goaway is expected with the actual last stream id that should be processed. Fixes #233
-rw-r--r--libsoup/http2/soup-client-message-io-http2.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/libsoup/http2/soup-client-message-io-http2.c b/libsoup/http2/soup-client-message-io-http2.c
index 16e46b02..b05fe299 100644
--- a/libsoup/http2/soup-client-message-io-http2.c
+++ b/libsoup/http2/soup-client-message-io-http2.c
@@ -653,6 +653,9 @@ handle_goaway (SoupClientMessageIOHTTP2 *io,
GHashTableIter iter;
SoupHTTP2MessageData *data;
+ if (last_stream_id == G_MAXINT32)
+ return;
+
g_hash_table_iter_init (&iter, io->messages);
while (g_hash_table_iter_next (&iter, NULL, (gpointer*)&data)) {
/* If there is no error it is a graceful shutdown and