aboutsummaryrefslogtreecommitdiff
path: root/src
AgeCommit message (Collapse)Author
2019-12-05lib: fix some loose ends for recently added CURLSSLOPT_NO_PARTIALCHAINJay Satiro
Add support for CURLSSLOPT_NO_PARTIALCHAIN in CURLOPT_PROXY_SSL_OPTIONS and OS400 package spec. Also I added the option to the NameValue list in the tool even though it isn't exposed as a command-line option (...yet?). (NameValue stringizes the option name for the curl cmd -> libcurl source generator) Follow-up to 564d88a which added CURLSSLOPT_NO_PARTIALCHAIN. Ref: https://github.com/curl/curl/pull/4655
2019-12-05etag: allow both --etag-compare and --etag-save in same cmdlineDaniel Stenberg
Fixes #4669 Closes #4678
2019-12-03curl: show better error message when no homedir is foundDaniel Stenberg
Reported-by: Vlastimil Ovčáčík Fixes #4644 Closes #4665
2019-12-02copyright: fix the year ranges for two filesDaniel Stenberg
Follow-up to 9c1806ae
2019-12-01build: Disable Visual Studio warning "conditional expression is constant"Jay Satiro
- Disable warning C4127 "conditional expression is constant" globally in curl_setup.h for when building with Microsoft's compiler. This mainly affects building with the Visual Studio project files found in the projects dir. Prior to this change the cmake and winbuild build systems already disabled 4127 globally for when building with Microsoft's compiler. Also, 4127 was already disabled for all build systems in the limited circumstance of the WHILE_FALSE macro which disabled the warning specifically for while(0). This commit removes the WHILE_FALSE macro and all other cruft in favor of disabling globally in curl_setup. Background: We have various macros that cause 0 or 1 to be evaluated, which would cause warning C4127 in Visual Studio. For example this causes it: #define Curl_resolver_asynch() 1 Full behavior is not clearly defined and inconsistent across versions. However it is documented that since VS 2015 Update 3 Microsoft has addressed this somewhat but not entirely, not warning on while(true) for example. Prior to this change some C4127 warnings occurred when I built with Visual Studio using the generated projects in the projects dir. Closes https://github.com/curl/curl/pull/4658
2019-11-28curl: two new command line options for etagsMaros Priputen
--etag-compare and --etag-save Suggested-by: Paul Hoffman Fixes #4277 Closes #4543
2019-11-26curl: fix --upload-file . hangs if delay in STDINJohn Schroeder
Attempt to unpause a busy read in the CURLOPT_XFERINFOFUNCTION. When uploading from stdin in non-blocking mode, a delay in reading the stream (EAGAIN) causes curl to pause sending data (CURL_READFUNC_PAUSE). Prior to this change, a busy read was detected and unpaused only in the CURLOPT_WRITEFUNCTION handler. This change performs the same busy read handling in a CURLOPT_XFERINFOFUNCTION handler. Fixes #2051 Closes #4599 Reported-by: bdry on github
2019-11-21curl: add --parallel-immediateDaniel Stenberg
Starting with this change when doing parallel transfers, without this option set, curl will prefer to create new transfers multiplexed on an existing connection rather than creating a brand new one. --parallel-immediate can be set to tell curl to prefer to use new connections rather than to wait and try to multiplex. libcurl-wise, this means that curl will set CURLOPT_PIPEWAIT by default on parallel transfers. Suggested-by: Tom van der Woerdt Closes #4500
2019-11-14curl: fix -T globbingDaniel Stenberg
Regression from e59371a4936f8 (7.67.0) Added test 490, 491 and 492 to verify the functionality. Reported-by: Kamil Dudka Reported-by: Anderson Sasaki Fixes #4588 Closes #4591
2019-11-08copyrights: fix copyright year rangeDaniel Stenberg
.. because checksrc's copyright year check stopped working. Ref: https://github.com/curl/curl/pull/4547 Closes https://github.com/curl/curl/pull/4549
2019-10-16tool_operate: Fix retry sleep time shown to user when Retry-AfterStian Soiland-Reyes
- If server header Retry-After is being used for retry sleep time then show that value to the user instead of the normal retry sleep time. This is a follow-up to 640b973 (7.66.0) which changed curl tool so that the value from Retry-After header overrides other retry timing options. Closes https://github.com/curl/curl/pull/4498
2019-10-09docs: document it as --no-progress-meter instead of the reverseDaniel Stenberg
Follow-up to 93373a960c3bb4 Reported-by: infinnovation-dev on github Fixes #4474 Closes #4475
2019-10-08curl: --no-progress-meterDaniel Stenberg
New option that allows a user to ONLY switch off curl's progress meter and leave everything else in "talkative" mode. Reported-by: Piotr Komborski Fixes #4422 Closes #4470
2019-10-05curl: ensure HTTP 429 triggers --retryStian Soiland-Reyes
This completes #3794. Also make sure the new tests from #4195 are enabled Closes #4465
2019-10-02ESNI: initial build/setupNiall
Closes #4011
2019-10-02tool_operate: rename functions to make more senseDaniel Stenberg
2019-10-02curl: create easy handles on-demand and not ahead of timeDaniel Stenberg
This should again enable crazy-large download ranges of the style [1-10000000] that otherwise easily ran out of memory starting in 7.66.0 when this new handle allocating scheme was introduced. Reported-by: Peter Sumatra Fixes #4393 Closes #4438
2019-09-22curl: exit the create_transfers loop on errorsDaniel Stenberg
When looping around the ranges and given URLs to create transfers, all errors should exit the loop and return. Previously it would keep looping. Reported-by: SumatraPeter on github Bug: #4393 Closes #4396
2019-09-20tool_operate: removed unused variable 'done'Daniel Stenberg
Fixes warning detected by PVS-Studio Fixes #4374
2019-09-20tool_operate: Expression 'config->resume_from' is always trueDaniel Stenberg
Fixes warning detected by PVS-Studio Fixes #4374
2019-09-20tool_getparam: remove duplicate switch caseDaniel Stenberg
Fixes warning detected by PVS-Studio Fixes #4374
2019-09-13curl: fix memory leaked by parse_metalink()Kamil Dudka
This commit fixes a regression introduced by curl-7_65_3-5-gb88940850. Detected by tests 2005, 2008, 2009, 2010, 2011, and 2012 with valgrind and libmetalink enabled. Closes #4326
2019-09-13curl:file2string: load large files much fasterGilles Vollant
... by using a more efficient realloc scheme. Bug: https://curl.haxx.se/mail/lib-2019-09/0045.html Closes #4336
2019-09-10curl: make sure the parallel transfers do them allDaniel Stenberg
The logic could erroneously break the loop too early before all transfers had been transferred. Reported-by: Tom van der Woerdt Fixes #4316 Closes #4317
2019-09-09tool_setopt: handle a libcurl build without netrc supportDaniel Stenberg
Reported-by: codesniffer13 on github Fixes #4302 Closes #4305
2019-08-29curl: fix include conditionslufia
2019-08-20cleanup: remove DOT_CHAR completelyDaniel Stenberg
Follow-up to f9c7ba9096ec The use of DOT_CHAR for ".ssh" was probably a mistake and is removed now. Pointed-out-by: Gisle Vanem Bug: https://github.com/curl/curl/pull/4230#issuecomment-522960638 Closes #4247
2019-08-20curl: make --libcurl use CURL_HTTP_VERSION_3Daniel Stenberg
Closes #4243
2019-08-20curl: use .curlrc (with a dot) on Windows as wellDaniel Stenberg
Fall-back to _curlrc if the dot-version is missing. Co-Authored-By: Steve Holme Closes #4230
2019-08-08cleanup: s/curl_debug/curl_dbg_debug in comments and docsDaniel Stenberg
Leftovers from the function rename back in 76b63489495 Reported-by: Gisle Vanem Bug: https://github.com/curl/curl/commit/f3e0f071b14fcb46a453f69bdf4e062bcaacf362#com mitcomment-34601751 Closes #4203
2019-08-08CURLOPT_HTTP_VERSION: seting this to 3 forces HTTP/3 use directlyDaniel Stenberg
Even though it cannot fall-back to a lower HTTP version automatically. The safer way to upgrade remains via CURLOPT_ALTSVC. CURLOPT_H3 no longer has any bits that do anything and might be removed before we remove the experimental label. Updated the curl tool accordingly to use "--http3". Closes #4197
2019-08-07curl: make use of CURLINFO_RETRY_AFTER when retryingDaniel Stenberg
If a Retry-After: header was used in the response, that value overrides other retry timing options. Fixes #3794 Closes #4195
2019-08-07curl: use CURLINFO_PROTOCOL to check for HTTP(s)Daniel Stenberg
... instead of CURLINFO_EFFECTIVE_URL to avoid string operations.
2019-08-07curl: have -w's 'http_version' show '3' for HTTP/3Daniel Stenberg
Closes #4196
2019-08-06curl: --sasl-authzid added to support CURLOPT_SASL_AUTHZID from the toolSteve Holme
Ref: https://github.com/curl/curl/issues/3653 Ref: https://github.com/curl/curl/pull/3790 NOTE: This commit was cherry-picked and is part of a series of commits that added the authzid feature for upcoming 7.66.0. The series was temporarily reverted in db8ec1f so that it would not ship in a 7.65.x patch release. Closes https://github.com/curl/curl/pull/4186
2019-08-06curl_multi_poll: a sister to curl_multi_wait() that waits moreDaniel Stenberg
Repeatedly we see problems where using curl_multi_wait() is difficult or just awkward because if it has no file descriptor to wait for internally, it returns immediately and leaves it to the caller to wait for a small amount of time in order to avoid occasional busy-looping. This is often missed or misunderstood, leading to underperforming applications. This change introduces curl_multi_poll() as a replacement drop-in function that accepts the exact same set of arguments. This function works identically to curl_multi_wait() - EXCEPT - for the case when there's nothing to wait for internally, as then this function will by itself wait for a "suitable" short time before it returns. This effectiely avoids all risks of busy-looping and should also make it less likely that apps "over-wait". This also changes the curl tool to use this funtion internally when doing parallel transfers and changes curl_easy_perform() to use it internally. Closes #4163
2019-08-06http09: disable HTTP/0.9 by default in both tool and libraryDaniel Stenberg
As the plan has been laid out in DEPRECATED. Update docs accordingly and verify in test 1174. Now requires the option to be set to allow HTTP/0.9 responses. Closes #4191
2019-08-01src/makefile: fix uncompressed hugehelp.c generationDaniel Stenberg
Regression from 5cf5d57ab9 (7.64.1) Fixed-by: Lance Ware Fixes #4176 Closes #4177
2019-07-30curl: remove outdated commentDaniel Stenberg
Turned bad with commit b8894085000 Reported-by: niallor on github Fixes #4172 Closes #4173
2019-07-30curl: cap the maximum allowed values for retry time argumentsDaniel Stenberg
... to avoid integer overflows later when multiplying with 1000 to convert seconds to milliseconds. Added test 1269 to verify. Reported-by: Jason Lee Closes #4166
2019-07-29curl: avoid uncessary libcurl timeouts (in parallel mode)Daniel Stenberg
When curl_multi_wait() returns OK without file descriptors to wait for, it might already have done a long timeout. Closes #4159
2019-07-23tool_operate: fix implicit call to easysrc_cleanupJay Satiro
easysrc_cleanup is only defined when CURL_DISABLE_LIBCURL_OPTION is not defined, and prior to this change would be called regardless. Bug: https://github.com/curl/curl/pull/3804#issuecomment-513922637 Reported-by: Marcel Raad Closes https://github.com/curl/curl/pull/4142
2019-07-22curl:create_transfers check return code from curl_easy_setoptDaniel Stenberg
From commit b8894085 Pointed out by Coverity CID 1451703 Closes #4134
2019-07-21HTTP3: initial (experimental) supportDaniel Stenberg
USe configure --with-ngtcp2 or --with-quiche Using either option will enable a HTTP3 build. Co-authored-by: Alessandro Ghedini <alessandro@ghedini.me> Closes #3500
2019-07-21curl: remove dead codeDaniel Stenberg
The loop never loops (since b889408500), pointed out by Coverity (CID 1451702) Closes #4133
2019-07-20curl: support parallel transfersDaniel Stenberg
This is done by making sure each individual transfer is first added to a linked list as then they can be performed serially, or at will, in parallel. Closes #3804
2019-07-16curl: only accept COLUMNS less than 10000Daniel Stenberg
... as larger values would rather indicate something silly (and could potentially cause buffer problems). Reported-by: pendrek at hackerone Closes #4114
2019-06-24curl: skip CURLOPT_PROXY_CAPATH for disabled-proxy buildsKoen Dergent
Closes #4061
2019-06-18curl: improved skip-setopt-options when built with disabled featuresDaniel Stenberg
Reduces #ifdefs in src/tool_operate.c Follow-up from 4e86f2fc4e6 Closes #3936
2019-06-10tool_cb_prg: Fix integer overflow in progress barDaniel Gustafsson
Commit 61faa0b420c236480bc9ef6fd52b4ecc1e0f8d17 fixed the progress bar width calculation to avoid integer overflow, but failed to account for the fact that initial_size is initialized to -1 when the file size is retrieved from the remote on an upload, causing another signed integer overflow. Fix by separately checking for this case before the width calculation. Closes #3984 Reported-by: Brian Carpenter (Geeknik Labs) Reviewed-by: Daniel Stenberg <daniel@haxx.se>