[libsoup/libsoup-3-0] http2: handle the case of last stream id being max int32 in goaway



commit 7413504b5dc939be9f3dfa4ffa8fdd04dcac773f
Author: Carlos Garcia Campos <cgarcia igalia com>
Date:   Wed Jun 29 14:57:15 2022 +0200

    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

 libsoup/http2/soup-client-message-io-http2.c | 3 +++
 1 file changed, 3 insertions(+)
---
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


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]