#
00bef959 |
| 20-Apr-2024 |
Gusted |
tool_operate: don't truncate the etag save file by default This fixes a regression of 75d79a4486b279100209ddf8c7fdb12955fb66e9. The code in tool-operate truncated the etag save file, und
tool_operate: don't truncate the etag save file by default This fixes a regression of 75d79a4486b279100209ddf8c7fdb12955fb66e9. The code in tool-operate truncated the etag save file, under the assumption that the file would be written with a new etag value. However since 75d79a4486b279100209ddf8c7fdb12955fb66e9 that might not be the case anymore and could result in the file being truncated when --etag-compare and --etag-save was used and that the etag value matched with what the server responded. Instead the truncation should not be done when a new etag value should be written. Test 3204 was added to verify that the file with the etag value doesn't change the contents when used by --etag-compare and --etage-save and that value matches with what the server returns on a non 2xx response. Closes #13432
show more ...
|
#
9126b141 |
| 30-Mar-2024 |
Daniel Stenberg |
curl: use curl_getenv instead of the curlx_ version The curlx one was once introduced when we still considered dropping the libcurl function at some point. To reduce confusion and to mak
curl: use curl_getenv instead of the curlx_ version The curlx one was once introduced when we still considered dropping the libcurl function at some point. To reduce confusion and to make it easier to understand when curl_free() should be used, use the actual libcurl function call directly instead. Closes #13230
show more ...
|
#
75d79a44 |
| 05-Feb-2024 |
Daniel Stenberg |
tool_cb_hdr: only parse etag + content-disposition for 2xx ... and ignore them for other response codes. Reported-by: Harry Sintonen Closes #12866
|
#
941b56d7 |
| 02-Jan-2024 |
Daniel Stenberg |
tool: prepend output_dir in header callback When Content-Disposition parsing is used and an output dir is prepended, make sure to store that new file name correctly so that it can be use
tool: prepend output_dir in header callback When Content-Disposition parsing is used and an output dir is prepended, make sure to store that new file name correctly so that it can be used for setting the file timestamp when --remote-time is used. Extended test 3012 to verify. Co-Authored-by: Jay Satiro Reported-by: hgdagon on github Fixes #12614 Closes #12617
show more ...
|
#
e9a7d4a1 |
| 21-Nov-2023 |
Viktor Szakats |
windows: use built-in `_WIN32` macro to detect Windows Windows compilers define `_WIN32` automatically. Windows SDK headers or build env defines `WIN32`, or we have to take care of it. T
windows: use built-in `_WIN32` macro to detect Windows Windows compilers define `_WIN32` automatically. Windows SDK headers or build env defines `WIN32`, or we have to take care of it. The agreement seems to be that `_WIN32` is the preferred practice here. Make the source code rely on that to detect we're building for Windows. Public `curl.h` was using `WIN32`, `__WIN32__` and `CURL_WIN32` for Windows detection, next to the official `_WIN32`. After this patch it only uses `_WIN32` for this. Also, make it stop defining `CURL_WIN32`. There is a slight chance these break compatibility with Windows compilers that fail to define `_WIN32`. I'm not aware of any obsolete or modern compiler affected, but in case there is one, one possible solution is to define this macro manually. grepping for `WIN32` remains useful to discover Windows-specific code. Also: - extend `checksrc` to ensure we're not using `WIN32` anymore. - apply minor formatting here and there. - delete unnecessary checks for `!MSDOS` when `_WIN32` is present. Co-authored-by: Jay Satiro Reviewed-by: Daniel Stenberg Closes #12376
show more ...
|
#
8261800f |
| 14-Nov-2023 |
Jay Satiro |
tool: support bold headers in Windows - If virtual terminal processing is enabled in Windows then use ANSI escape codes Esc[1m and Esc[22m to turn bold on and off. Suggested-b
tool: support bold headers in Windows - If virtual terminal processing is enabled in Windows then use ANSI escape codes Esc[1m and Esc[22m to turn bold on and off. Suggested-by: Gisle Vanem Ref: https://github.com/curl/curl/discussions/11770 Closes https://github.com/curl/curl/pull/12321
show more ...
|
#
efbbbf4f |
| 14-Nov-2023 |
Jay Satiro |
tool_cb_hdr: add an additional parsing check - Don't dereference the past-the-end element when parsing the server's Content-disposition header. As 'p' is advanced it can point
tool_cb_hdr: add an additional parsing check - Don't dereference the past-the-end element when parsing the server's Content-disposition header. As 'p' is advanced it can point to the past-the-end element and prior to this change 'p' could be dereferenced in that case. Technically the past-the-end element is not out of bounds because dynbuf (which manages the header line) automatically adds a null terminator to every buffer and that is not included in the buffer length passed to the header callback. Closes https://github.com/curl/curl/pull/12320
show more ...
|
#
226d042a |
| 25-Aug-2023 |
Davide Masserut |
tool: avoid including leading spaces in the Location hyperlink Co-authored-by: Dan Fandrich <dan@coneharvesters.com> Closes #11735
|
#
ce1fc742 |
| 02-Aug-2023 |
Daniel Stenberg |
tool: make the length argument an int for printf()-.* flags Closes #11578
|
#
af3f4e41 |
| 04-Apr-2023 |
Jay Satiro |
tool_cb_wrt: fix invalid unicode for windows console - Suppress an incomplete UTF-8 sequence at the end of the buffer. - Attempt to reconstruct incomplete UTF-8 sequence from prior
tool_cb_wrt: fix invalid unicode for windows console - Suppress an incomplete UTF-8 sequence at the end of the buffer. - Attempt to reconstruct incomplete UTF-8 sequence from prior call(s) in current call. Prior to this change, in Windows console UTF-8 sequences split between two or more calls to the write callback would cause invalid "replacement characters" U+FFFD to be printed instead of the actual Unicode character. This is because in Windows only UTF-16 encoded characters are printed to the console, therefore we convert the UTF-8 contents to UTF-16, which cannot be done with partial UTF-8 sequences. Reported-by: Maksim Arhipov Fixes https://github.com/curl/curl/issues/9841 Closes https://github.com/curl/curl/pull/10890
show more ...
|
#
6661bd58 |
| 31-May-2023 |
Daniel Stenberg |
tool: remove exclamation marks from error/warning messages
|
#
6d45b9ca |
| 30-May-2023 |
Daniel Stenberg |
tool: remove newlines from all helpf/notef/warnf/errorf calls Make voutf() always add one. Closes #11226
|
#
30ba26d9 |
| 03-May-2023 |
Jay Satiro |
tool_cb_hdr: Fix 'Location:' formatting for early VTE terminals - Disable hyperlink formatting for the 'Location:' header value in VTE 0.48.1 and earlier, since it is buggy in some of
tool_cb_hdr: Fix 'Location:' formatting for early VTE terminals - Disable hyperlink formatting for the 'Location:' header value in VTE 0.48.1 and earlier, since it is buggy in some of those versions. Prior to this change those terminals may show the location header value as gibberish or show it twice. Ref: https://gist.github.com/egmontkob/eb114294efbcd5adb1944c9f3cb5feda#backward-compatibility Fixes https://github.com/curl/curl/issues/10428 Closes https://github.com/curl/curl/pull/11071
show more ...
|
#
2bc1d775 |
| 02-Jan-2023 |
Daniel Stenberg |
copyright: update all copyright lines and remove year ranges - they are mostly pointless in all major jurisdictions - many big corporations and projects already don't use them - save
copyright: update all copyright lines and remove year ranges - they are mostly pointless in all major jurisdictions - many big corporations and projects already don't use them - saves us from pointless churn - git keeps history for us - the year range is kept in COPYING checksrc is updated to allow non-year using copyright statements Closes #10205
show more ...
|
#
6d751154 |
| 08-Nov-2022 |
Jay Satiro |
lib: add CURL_WRITEFUNC_ERROR to signal write callback error Prior to this change if the user wanted to signal an error from their write callbacks they would have to use logic to return
lib: add CURL_WRITEFUNC_ERROR to signal write callback error Prior to this change if the user wanted to signal an error from their write callbacks they would have to use logic to return a value different from the number of bytes (nmemb) passed to the callback. Also, the inclination of some users has been to just return 0 to signal error, which is incorrect as that may be the number of bytes passed to the callback. To remedy this the user can now return CURL_WRITEFUNC_ERROR instead. Ref: https://github.com/curl/curl/issues/9873 Closes https://github.com/curl/curl/pull/9874
show more ...
|
#
677266c7 |
| 21-Sep-2022 |
Patrick Monnerat |
tool: remove protocol count limitation Replace bit mask protocol sets by null-terminated arrays of protocol tokens. These are the addresses of the protocol names returned by curl_ver
tool: remove protocol count limitation Replace bit mask protocol sets by null-terminated arrays of protocol tokens. These are the addresses of the protocol names returned by curl_version_info(). Protocol names are sorted case-insensitively before output to satisfy CI tests matches consistency. The protocol list returned by curl_version_info() is augmented with all RTMP protocol variants. Test 1401 adjusted for new alpha ordered output. Closes #9546
show more ...
|
#
dd2a0243 |
| 15-Sep-2022 |
Patrick Monnerat |
cli tool: do not use disabled protocols As they are now rejected by the library, take care of not passing disabled protocol names to CURLOPT_PROTOCOLS_STR and CURLOPT_REDIR_PROTOCOLS
cli tool: do not use disabled protocols As they are now rejected by the library, take care of not passing disabled protocol names to CURLOPT_PROTOCOLS_STR and CURLOPT_REDIR_PROTOCOLS_STR. Rather than using the CURLPROTO_* constants, dynamically assign protocol numbers based on the order they are listed by curl_version_info(). New type proto_set_t implements prototype bit masks: it should therefore be large enough to accomodate all library-enabled protocols. If not, protocol numbers beyond the bit count of proto_set_t are recognized but "inaccessible": when used, a warning is displayed and the value is ignored. Should proto_set_t overflows, enabled protocols are reordered to force those having a public CURLPROTO_* representation to be accessible. Code has been added to subordinate RTMP?* protocols to the presence of RTMP in the enabled protocol list, being returned by curl_version_info() or not.
show more ...
|
#
6f9fb7ec |
| 05-Sep-2022 |
Daniel Stenberg |
misc: ISSPACE() => ISBLANK() Instances of ISSPACE() use that should rather use ISBLANK(). I think somewhat carelessly used because it sounds as if it checks for space or whitespace,
misc: ISSPACE() => ISBLANK() Instances of ISSPACE() use that should rather use ISBLANK(). I think somewhat carelessly used because it sounds as if it checks for space or whitespace, but also includes %0a to %0d. For parsing purposes, we should only accept what we must and not be overly liberal. It leads to surprises and surprises lead to bad things. Closes #9432
show more ...
|
#
ad9bc597 |
| 17-May-2022 |
max.mehl |
copyright: make repository REUSE compliant Add licensing and copyright information for all files in this repository. This either happens in the file itself as a comment header or in the
copyright: make repository REUSE compliant Add licensing and copyright information for all files in this repository. This either happens in the file itself as a comment header or in the file `.reuse/dep5`. This commit also adds a Github workflow to check pull requests and adapts copyright.pl to the changes. Closes #8869
show more ...
|
#
4ec0549c |
| 25-Apr-2022 |
Daniel Stenberg |
misc: update copyright year ranges
|
#
3055c4c8 |
| 05-Nov-2021 |
Dan Fandrich |
tool_cb_hdr: Turn the Location: into a terminal hyperlink This turns even relative URLs into clickable hyperlinks in a supported terminal when --styled-output is enabled. Many terminals
tool_cb_hdr: Turn the Location: into a terminal hyperlink This turns even relative URLs into clickable hyperlinks in a supported terminal when --styled-output is enabled. Many terminals already turn URLs into clickable links but there is not enough information in a relative URL to do this automatically otherwise.
show more ...
|
Revision tags: curl-7_76_1, curl-7_76_0, curl-7_75_0, curl-7_74_0 |
|
#
4d2f8006 |
| 04-Nov-2020 |
Daniel Stenberg |
curl.se: new home Closes #6172
|
Revision tags: curl-7_73_0 |
|
#
0c1e767e |
| 09-Sep-2020 |
anio |
tool_writeout: add new writeout variable, %{num_headers} This variable gives the number of headers. Closes #5947
|
Revision tags: tiny-curl-7_72_0 |
|
#
98c94596 |
| 19-Aug-2020 |
Daniel Stenberg |
etag: save and use the full received contents ... which makes it support weak tags and non-standard etags too! Added test case 347 to verify blank incoming ETag: Fixes #561
etag: save and use the full received contents ... which makes it support weak tags and non-standard etags too! Added test case 347 to verify blank incoming ETag: Fixes #5610 Closes #5833
show more ...
|
Revision tags: curl-7_72_0, curl-7_71_1 |
|
#
cb852753 |
| 26-Jun-2020 |
Jay Satiro |
tool_cb_hdr: Fix etag warning output and return code - Return 'failure' on failure, to follow the existing style. - Put Warning: and the warning message on the same line. R
tool_cb_hdr: Fix etag warning output and return code - Return 'failure' on failure, to follow the existing style. - Put Warning: and the warning message on the same line. Ref: https://github.com/curl/curl/issues/5610 Closes https://github.com/curl/curl/pull/5612
show more ...
|