1
0
mirror of https://github.com/moparisthebest/curl synced 2024-11-04 16:45:06 -05:00
Go to file
Christopher Head 9526cbe6bc
docs/CURLOPT_WRITEFUNCTION: size is always 1
For compatibility with `fwrite`, the `CURLOPT_WRITEFUNCTION` callback is
passed two `size_t` parameters which, when multiplied, designate the
number of bytes of data passed in. In practice, CURL always sets the
first parameter (`size`) to 1.

This practice is also enshrined in documentation and cannot be changed
in future. The documentation states that the default callback is
`fwrite`, which means `fwrite` must be a suitable function for this
purpose. However, the documentation also states that the callback must
return the number of *bytes* it successfully handled, whereas ISO C
`fwrite` returns the number of items (each of size `size`) which it
wrote. The only way these numbers can be equal is if `size` is 1.

Since `size` is 1 and can never be changed in future anyway, document
that fact explicitly and let users rely on it.

Closes #2787
2018-07-26 16:24:43 +02:00
.github github/lock: auto-lock closed issues after 90 days of inactivity 2018-05-05 14:05:57 +02:00
CMake CMake: Update scripts to use consistent style 2018-07-17 11:54:07 +02:00
docs docs/CURLOPT_WRITEFUNCTION: size is always 1 2018-07-26 16:24:43 +02:00
include RELEASE-NOTES: sync 2018-07-18 01:21:07 +02:00
lib wolfSSL/CyaSSL: Fix memory leak in Curl_cyassl_random 2018-07-26 16:21:59 +02:00
m4 curl-confopts.m4: fix typo from ed224f23d5 2018-06-15 17:14:05 +02:00
packages spelling fixes 2018-06-03 12:14:45 +00:00
projects spelling fixes 2018-06-03 12:14:45 +00:00
scripts scripts: include _curl as part of CLEANFILES 2018-07-08 23:20:11 +02:00
src CMake: Update scripts to use consistent style 2018-07-17 11:54:07 +02:00
tests test320: treat curl320.out file as binary 2018-07-22 23:17:06 +02:00
winbuild curl.rc: embed manifest for correct Windows version detection 2018-05-30 12:08:26 +00:00
.dir-locals.el Add .dir-locals and set c-basic-offset to 2. 2015-12-23 10:16:14 +01:00
.gitattributes .gitattributes: force shell scripts to LF 2017-04-17 08:32:13 +02:00
.gitignore ossfuzz: Move to C++ for curl_fuzzer. 2017-09-02 11:07:55 +02:00
.lgtm.yml CI: add lgtm.yml for tweaking lgtm.com analysis 2018-03-22 00:04:55 +01:00
.mailmap mailmap: Max Savenkov 2018-05-28 07:45:51 +02:00
.travis-iconv-env.sh travis: add build with iconv enabled 2018-02-15 14:18:34 +01:00
.travis.yml travis: add a build using the synchronous name resolver 2018-06-27 16:00:37 +02:00
acinclude.m4 configure: remove CURL_CHECK_NI_WITHSCOPEID too 2018-06-27 13:53:26 +02:00
appveyor.yml appveyor: add a win32 build 2017-10-27 23:40:04 +02:00
buildconf includes: remove curl/curlbuild.h and curl/curlrules.h 2017-06-14 11:07:33 +02:00
buildconf.bat includes: remove curl/curlbuild.h and curl/curlrules.h 2017-06-14 11:07:33 +02:00
CHANGES CHANGES: spell fix, use correct path to script 2017-02-07 08:22:37 +01:00
CMakeLists.txt CMake: Update scripts to use consistent style 2018-07-17 11:54:07 +02:00
configure.ac configure: remove CURL_CHECK_NI_WITHSCOPEID too 2018-06-27 13:53:26 +02:00
COPYING COPYING: it's 2018! 2018-01-09 17:08:14 +13:00
curl-config.in curl-config: add --ssl-backends 2017-12-06 00:12:48 +01:00
GIT-INFO CHANGES.0: removed 2017-02-07 08:20:10 +01:00
libcurl.pc.in URLs: change all http:// URLs to https:// 2016-02-03 00:19:02 +01:00
MacOSX-Framework includes: remove curl/curlbuild.h and curl/curlrules.h 2017-06-14 11:07:33 +02:00
Makefile.am build: Fixed incorrect script termination from commit ad1dc10e61 2017-12-22 20:21:40 +00:00
Makefile.dist build: remove the Borland specific makefiles 2018-06-02 11:23:40 +02:00
maketgz maketgz: delete .bak files, fix indentation 2018-06-15 23:28:34 +00:00
README URLs: follow GitHub project rename (also Travis CI) 2016-02-04 23:01:38 +01:00
README.md README.md: add backers and sponsors 2018-04-17 00:27:31 +02:00
RELEASE-NOTES RELEASE-NOTES: sync 2018-07-18 01:21:07 +02:00

curl logo

CII Best Practices Coverity passed Build Status Coverage Status Backers on Open Collective Sponsors on Open Collective

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 find answers to the most frequent questions we get in the FAQ document.

Study the COPYING file for distribution terms and similar. If you distribute curl binaries or other binaries that involve libcurl, you might enjoy the LICENSE-MIXING document.

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.

Website

Visit the curl web site 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)

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]