mirror of
https://github.com/curl/curl.git
synced 2026-07-26 13:27:16 +03:00
urldata: move async resolver state from easy handle to connectdata
- resolving is done for a connection, not for every transfer - save create/dup/free of a cares channel for each transfer - check values of setopt calls against a local channel if no connection has been attached yet, when needed. Closes #12198
This commit is contained in:
parent
910f740ce2
commit
56a4db2e4e
10 changed files with 147 additions and 127 deletions
|
|
@ -339,8 +339,8 @@ static CURLproxycode do_SOCKS4(struct Curl_cfilter *cf,
|
|||
|
||||
if(dns) {
|
||||
#ifdef CURLRES_ASYNCH
|
||||
data->state.async.dns = dns;
|
||||
data->state.async.done = TRUE;
|
||||
conn->resolve_async.dns = dns;
|
||||
conn->resolve_async.done = TRUE;
|
||||
#endif
|
||||
infof(data, "Hostname '%s' was found", sx->hostname);
|
||||
sxstate(sx, data, CONNECT_RESOLVED);
|
||||
|
|
@ -806,8 +806,8 @@ CONNECT_REQ_INIT:
|
|||
|
||||
if(dns) {
|
||||
#ifdef CURLRES_ASYNCH
|
||||
data->state.async.dns = dns;
|
||||
data->state.async.done = TRUE;
|
||||
conn->resolve_async.dns = dns;
|
||||
conn->resolve_async.done = TRUE;
|
||||
#endif
|
||||
infof(data, "SOCKS5: hostname '%s' found", sx->hostname);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue