diff options
author | Stefan Eissing <stefan@eissing.org> | 2023-04-24 12:50:44 +0200 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2023-04-25 17:50:53 +0200 |
commit | 5622e431edd748452a4bdb179f45c405357f0618 (patch) | |
tree | 2f28144dd1381be551d36c0e0ca75d9856bf33e9 | |
parent | fbea71f29338cbfd2161440ff94e8c0f2eeecbc8 (diff) | |
download | curl-5622e431edd748452a4bdb179f45c405357f0618.tar.gz |
http2: always EXPIRE_RUN_NOW unpaused http/2 transfers
- just increasing the http/2 flow window does not necessarily
make a server send new data. It may already have exhausted
the window before
Closes #11005
-rw-r--r-- | lib/http2.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/lib/http2.c b/lib/http2.c index 39b80a1bf..726f5a64b 100644 --- a/lib/http2.c +++ b/lib/http2.c @@ -2210,6 +2210,15 @@ static CURLcode http2_data_pause(struct Curl_cfilter *cf, if(result) return result; + if(!pause) { + /* Unpausing a h2 transfer, requires it to be run again. The server + * may send new DATA on us increasing the flow window, and it may + * not. We may have already buffered and exhausted the new window + * by operating on things in flight during the handling of other + * transfers. */ + drain_stream(cf, data, stream); + Curl_expire(data, 0, EXPIRE_RUN_NOW); + } DEBUGF(infof(data, "Set HTTP/2 window size to %u for stream %u", window, stream->id)); |