mirror of
https://github.com/curl/curl.git
synced 2026-08-25 13:33:36 +03:00
transfer: adjust_pollset improvements
- let `multi_getsock()` initialize the pollset in what the transfer state requires in regards to SEND/RECV - change connection filters `adjust_pollset()` implementation to react on the presence of POLLIN/-OUT in the pollset and no longer check CURL_WANT_SEND/CURL_WANT_RECV - cf-socket will no longer add POLLIN on its own - http2 and http/3 filters will only do adjustments if the passed pollset wants to POLLIN/OUT for the transfer on the socket. This is similar to the HTTP/2 proxy filter and works in stacked filters. Closes #12640
This commit is contained in:
parent
8edcfedc1a
commit
a0f94800d5
10 changed files with 125 additions and 107 deletions
|
|
@ -1243,7 +1243,7 @@ static void cf_socket_adjust_pollset(struct Curl_cfilter *cf,
|
|||
if(ctx->sock != CURL_SOCKET_BAD) {
|
||||
if(!cf->connected)
|
||||
Curl_pollset_set_out_only(data, ps, ctx->sock);
|
||||
else if(CURL_WANT_RECV(data))
|
||||
else if(!ctx->active)
|
||||
Curl_pollset_add_in(data, ps, ctx->sock);
|
||||
CURL_TRC_CF(data, cf, "adjust_pollset -> %d socks", ps->num);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue