mirror of
https://github.com/curl/curl.git
synced 2026-08-12 16:11:24 +03:00
url: Add option CURLOPT_HAPPY_EYEBALLS_TIMEOUT
- Add new option CURLOPT_HAPPY_EYEBALLS_TIMEOUT to set libcurl's happy eyeball timeout value. - Add new optval macro CURL_HET_DEFAULT to represent the default happy eyeballs timeout value (currently 200 ms). - Add new tool option --happy-eyeballs-timeout-ms to expose CURLOPT_HAPPY_EYEBALLS_TIMEOUT. The -ms suffix is used because the other -timeout options in the tool expect seconds not milliseconds. Closes https://github.com/curl/curl/pull/2260
This commit is contained in:
parent
73050fb6ae
commit
2427d94c6d
18 changed files with 125 additions and 5 deletions
|
|
@ -791,6 +791,11 @@ typedef enum {
|
|||
SSL backends where such behavior is present. */
|
||||
#define CURLSSLOPT_NO_REVOKE (1<<1)
|
||||
|
||||
/* The default connection attempt delay in milliseconds for happy eyeballs.
|
||||
CURLOPT_HAPPY_EYEBALLS_TIMEOUT.3 and happy-eyeballs-timeout-ms.d document
|
||||
this value, keep them in sync. */
|
||||
#define CURL_HET_DEFAULT 200L
|
||||
|
||||
#ifndef CURL_NO_OLDIES /* define this to test if your app builds with all
|
||||
the obsolete stuff removed! */
|
||||
|
||||
|
|
@ -1825,6 +1830,9 @@ typedef enum {
|
|||
seconds since 1 Jan 1970. */
|
||||
CINIT(TIMEVALUE_LARGE, OFF_T, 270),
|
||||
|
||||
/* Head start in milliseconds to give happy eyeballs. */
|
||||
CINIT(HAPPY_EYEBALLS_TIMEOUT, LONG, 271),
|
||||
|
||||
CURLOPT_LASTENTRY /* the last unused */
|
||||
} CURLoption;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue