mirror of
https://github.com/curl/curl.git
synced 2026-08-24 23:43:40 +03:00
multi: use larger dns hash table for multi interface
Have curl_multi_init() use a much larger DNS hash table than used for the easy interface to scale and perform better when used with _many_ host names. curl_share_init() sets an in-between size. Inspired-by: Ivan Tsybulin See #9340 Closes #9376
This commit is contained in:
parent
c5c6e86783
commit
7632c0d25a
7 changed files with 18 additions and 11 deletions
|
|
@ -1005,9 +1005,9 @@ static void freednsentry(void *freethis)
|
|||
/*
|
||||
* Curl_init_dnscache() inits a new DNS cache.
|
||||
*/
|
||||
void Curl_init_dnscache(struct Curl_hash *hash)
|
||||
void Curl_init_dnscache(struct Curl_hash *hash, int size)
|
||||
{
|
||||
Curl_hash_init(hash, 7, Curl_hash_str, Curl_str_key_compare,
|
||||
Curl_hash_init(hash, size, Curl_hash_str, Curl_str_key_compare,
|
||||
freednsentry);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue