diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/tool_cfgable.c | 3 | ||||
-rw-r--r-- | src/tool_operate.c | 4 | ||||
-rw-r--r-- | src/tool_setopt.c | 3 |
3 files changed, 6 insertions, 4 deletions
diff --git a/src/tool_cfgable.c b/src/tool_cfgable.c index 8b60a91b7..567123b82 100644 --- a/src/tool_cfgable.c +++ b/src/tool_cfgable.c @@ -5,7 +5,7 @@ * | (__| |_| | _ <| |___ * \___|\___/|_| \_\_____| * - * Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al. + * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al. * * This software is licensed as described in the file COPYING, which * you should have received as part of this distribution. The terms @@ -41,6 +41,7 @@ void config_init(struct OperationConfig* config) CURLPROTO_SMBS); config->proto_redir_present = FALSE; config->proto_default = NULL; + config->tcp_nodelay = TRUE; /* enabled by default */ } static void free_config_fields(struct OperationConfig *config) diff --git a/src/tool_operate.c b/src/tool_operate.c index 2b53c9a85..97bb87b3d 100644 --- a/src/tool_operate.c +++ b/src/tool_operate.c @@ -792,8 +792,8 @@ static CURLcode operate_do(struct GlobalConfig *global, set_binmode(stdout); } - if(config->tcp_nodelay) - my_setopt(curl, CURLOPT_TCP_NODELAY, 1L); + if(!config->tcp_nodelay) + my_setopt(curl, CURLOPT_TCP_NODELAY, 0L); if(config->tcp_fastopen) my_setopt(curl, CURLOPT_TCP_FASTOPEN, 1L); diff --git a/src/tool_setopt.c b/src/tool_setopt.c index 690ce14a6..c854225e4 100644 --- a/src/tool_setopt.c +++ b/src/tool_setopt.c @@ -5,7 +5,7 @@ * | (__| |_| | _ <| |___ * \___|\___/|_| \_\_____| * - * Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al. + * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al. * * This software is licensed as described in the file COPYING, which * you should have received as part of this distribution. The terms @@ -157,6 +157,7 @@ static const NameValue setopt_nv_CURLNONZERODEFAULTS[] = { NV1(CURLOPT_SSL_VERIFYHOST, 1), NV1(CURLOPT_SSL_ENABLE_NPN, 1), NV1(CURLOPT_SSL_ENABLE_ALPN, 1), + NV1(CURLOPT_TCP_NODELAY, 1), NVEND }; |