1
0
mirror of https://github.com/moparisthebest/curl synced 2025-02-28 17:31:46 -05:00
Romain Fliedel 6765e6d9e6
ares: remove fd from multi fd set when ares is about to close the fd
When using c-ares for asyn dns, the dns socket fd was silently closed
by c-ares without curl being aware. curl would then 'realize' the fd
has been removed at next call of Curl_resolver_getsock, and only then
notify the CURLMOPT_SOCKETFUNCTION to remove fd from its poll set with
CURL_POLL_REMOVE. At this point the fd is already closed.

By using ares socket state callback (ARES_OPT_SOCK_STATE_CB), this
patch allows curl to be notified that the fd is not longer needed
for neither for write nor read. At this point by calling
Curl_multi_closed we are able to notify multi with CURL_POLL_REMOVE
before the fd is actually closed by ares.

In asyn-ares.c Curl_resolver_duphandle we can't use ares_dup anymore
since it does not allow passing a different sock_state_cb_data

Closes #3238
2018-11-20 19:58:45 +01:00
..
2016-10-18 13:59:54 +02:00
2018-09-23 22:24:02 +00:00
2018-06-11 11:14:48 +02:00
2018-09-23 22:24:02 +00:00
2018-01-05 23:34:30 -05:00
2018-10-19 09:23:14 +02:00
2018-06-03 12:14:45 +00:00
2018-09-23 22:24:02 +00:00
2017-03-26 23:56:23 +02:00
2018-10-26 00:04:02 +02:00
2018-06-11 11:14:48 +02:00
2018-09-23 22:24:02 +00:00
2018-11-01 10:29:53 +01:00
2018-09-23 22:24:02 +00:00
2018-09-22 11:58:10 +02:00
2018-09-23 22:24:02 +00:00
2018-09-08 15:36:11 +02:00
2018-09-23 22:24:02 +00:00
2018-09-23 22:24:02 +00:00
2018-09-23 22:24:02 +00:00
2018-09-22 11:58:10 +02:00
2018-06-11 11:14:48 +02:00
2017-04-22 11:25:27 +02:00
2018-09-06 09:17:17 +02:00
2018-11-01 10:29:53 +01:00
2018-09-23 22:24:02 +00:00
2018-06-27 13:49:18 +02:00
2018-09-06 09:17:17 +02:00
2018-09-23 22:24:02 +00:00
2018-09-23 22:24:02 +00:00
2016-12-21 11:07:26 +01:00
2018-09-23 22:24:02 +00:00
2017-09-11 09:29:50 +02:00
2018-09-22 11:58:10 +02:00
2018-09-23 22:24:02 +00:00
2018-09-23 22:24:02 +00:00
2018-09-23 22:24:02 +00:00
2018-09-23 22:24:02 +00:00
2018-09-23 22:24:02 +00:00
2018-11-01 10:29:53 +01:00
2018-09-23 22:24:02 +00:00
2018-09-14 18:48:35 +00:00
2018-11-01 10:29:53 +01:00
2018-06-27 13:49:18 +02:00
2018-07-28 22:36:15 +02:00
2018-02-23 23:29:01 +00:00
2017-09-02 17:47:10 +01:00
2018-09-23 22:24:02 +00:00
2018-02-23 23:29:01 +00:00
2018-03-19 19:22:42 +01:00
2018-09-23 22:24:02 +00:00
2017-10-25 18:48:05 +02:00
2018-07-20 22:58:42 +02:00
2018-06-11 11:14:48 +02:00
2018-09-23 22:24:02 +00:00
2018-09-23 22:24:02 +00:00
2018-06-11 11:14:48 +02:00
2018-09-23 22:24:02 +00:00
2018-11-03 20:54:18 +01:00
2018-11-09 15:47:28 +01:00
2018-09-23 22:24:02 +00:00
2018-09-23 22:24:02 +00:00
2018-09-22 11:58:10 +02:00
2018-07-30 17:59:36 +02:00
2018-09-22 11:58:10 +02:00
2018-09-23 22:24:02 +00:00
2018-09-23 22:24:02 +00:00
2018-09-23 22:24:02 +00:00
2018-09-23 22:24:02 +00:00
2018-09-04 14:44:47 +00:00
2018-10-26 15:39:15 +02:00
2018-09-01 10:40:42 +02:00
2018-08-21 18:53:43 +02:00
2018-09-23 22:24:02 +00:00
2018-09-22 11:58:10 +02:00
2018-09-23 22:24:02 +00:00
2018-11-09 15:47:28 +01:00
2018-09-23 22:24:02 +00:00
2018-11-09 15:47:28 +01:00