mirror of
https://github.com/curl/curl.git
synced 2026-08-25 01:33:31 +03:00
HTTP/[23]: continue upload when state.drain is set
- as reported in #10433, HTTP/2 uploads may stall when a response is received before the upload is done. This happens when the data->state.drain is set for such a transfer, as the special handling in transfer.c from then on only cared about downloads. - add continuation of uploads, if applicable, in this case. - add pytest case test_07_12_upload_seq_large to reproduce this scenario (although, current nghttp2 implementation is using drain less often) Reported-by: Lucas Pardue Fixes #10433 Closes #10443
This commit is contained in:
parent
8c762f5998
commit
3de3ea6a64
4 changed files with 55 additions and 22 deletions
|
|
@ -1080,6 +1080,8 @@ CURLcode Curl_readwrite(struct connectdata *conn,
|
|||
if(data->state.drain) {
|
||||
select_res |= CURL_CSELECT_IN;
|
||||
DEBUGF(infof(data, "Curl_readwrite: forcibly told to drain data"));
|
||||
if((k->keepon & KEEP_SENDBITS) == KEEP_SEND)
|
||||
select_res |= CURL_CSELECT_OUT;
|
||||
}
|
||||
#endif
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue