Go to file
Jay Satiro 12284e008b connect: fix wrong format specifier in connect error string
0842175 (not in any release) used the wrong format specifier (long int)
for timediff_t. On an OS such as Windows libcurl's timediff_t (usually
64-bit) is bigger than long int (32-bit). In 32-bit Windows builds the
upper 32-bits of the timediff_t were erroneously then used by the next
format specifier. Usually since the timeout isn't larger than 32-bits
this would result in null as a pointer to the string with the reason for
the connection failing. On other OSes or maybe other compilers it could
probably result in garbage values (ie crash on deref).

Before:
Failed to connect to localhost port 12345 after 1201 ms: (nil)

After:
Failed to connect to localhost port 12345 after 1203 ms: Connection refused

Closes https://github.com/curl/curl/pull/7449
2021-07-20 02:16:53 -04:00
.circleci copyright: add boiler-plate headers to CI config files 2021-06-29 17:44:03 +02:00
.github GHA: run all tests for hyper too 2021-06-10 08:42:59 +02:00
.muse
CMake misc: copyright year range updates 2021-07-19 09:20:58 +02:00
docs docs/cmdline: fix grammar and typos 2021-07-20 02:12:32 -04:00
include misc: copyright year range updates 2021-07-19 09:20:58 +02:00
lib connect: fix wrong format specifier in connect error string 2021-07-20 02:16:53 -04:00
m4 misc: copyright year range updates 2021-07-19 09:20:58 +02:00
packages metalink: remove 2021-06-07 08:14:25 +02:00
plan9
projects docs: Fix typos 2021-07-03 22:11:26 +02:00
scripts misc: copyright year range updates 2021-07-19 09:20:58 +02:00
src docs: correct spelling errors and a broken link 2021-07-18 21:14:36 +02:00
tests cleanup: spell DoH with a lowercase o 2021-07-16 23:53:13 +02:00
winbuild winbuild: support alternate nghttp2 static lib name 2021-07-20 02:16:15 -04:00
zuul.d zuul: use the new rustls directory name 2021-06-30 08:19:31 +02:00
.azure-pipelines.yml
.cirrus.yml CI/cirrus: install impacket from PyPI instead of FreeBSD packages 2021-07-18 19:42:47 +02:00
.dcignore
.dir-locals.el
.gitattributes
.gitignore
.lgtm.yml metalink: remove 2021-06-07 08:14:25 +02:00
.mailmap mailmap: add Tobias and Timur 2021-07-19 09:20:58 +02:00
acinclude.m4
appveyor.yml
buildconf
buildconf.bat
CHANGES
CMakeLists.txt cmake: remove libssh2 feature checks 2021-07-05 22:44:00 +02:00
configure.ac configure: fix nghttp2 library name for static builds 2021-07-16 13:34:39 -04:00
COPYING
curl-config.in
GIT-INFO
libcurl.pc.in
MacOSX-Framework
Makefile.am
Makefile.dist
maketgz
README
README.md CI: remove travis details 2021-06-29 17:42:57 +02:00
RELEASE-NOTES RELEASE-NOTES: synced 2021-07-16 23:27:49 +02:00
SECURITY.md

curl logo

CII Best Practices Coverity passed AppVeyor Build Status Azure DevOps Build Status Cirrus Build Status Backers on Open Collective Sponsors on Open Collective Language Grade: C/C++ Codacy Badge Fuzzing Status

Curl is a command-line tool for transferring data specified with URL syntax. Find out how to use curl by reading the curl.1 man page or the MANUAL document. Find out how to install Curl by reading the INSTALL document.

libcurl is the library curl is using to do its job. It is readily available to be used by your software. Read the libcurl.3 man page to learn how!

You can find answers to the most frequent questions we get in the FAQ document.

Study the COPYING file for distribution terms.

Contact

If you have problems, questions, ideas or suggestions, please contact us by posting to a suitable mailing list.

All contributors to the project are listed in the THANKS document.

Commercial support

For commercial support, maybe private and dedicated help with your problems or applications using (lib)curl: https://curl.se/support.html

Website

Visit the curl website for the latest news and downloads.

Git

To download the very latest source from the Git server do this:

git clone https://github.com/curl/curl.git

(you'll get a directory named curl created, filled with the source code)

Security problems

Report suspected security problems via our HackerOne page and not in public!

Notice

Curl contains pieces of source code that is Copyright (c) 1998, 1999 Kungliga Tekniska Högskolan. This notice is included here to comply with the distribution terms.

Backers

Thank you to all our backers! 🙏 [Become a backer]

Sponsors

Support this project by becoming a sponsor. Your logo will show up here with a link to your website. [Become a sponsor]