aboutsummaryrefslogtreecommitdiff
path: root/docs/libcurl/opts/CURLOPT_WRITEFUNCTION.3
AgeCommit message (Collapse)Author
2020-04-07CURLOPT_WRITEFUNCTION.3: add inline example and new see-alsoDaniel Stenberg
Closes #5192
2018-11-23CURLOPT_WRITEFUNCTION.3: spell out that it gets called many timesDaniel Stenberg
2018-07-26docs/CURLOPT_WRITEFUNCTION: size is always 1Christopher Head
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
2016-02-03URLs: change all http:// URLs to https://Daniel Stenberg
2014-06-17CURLOPT_WRITEFUNCTION: changed the order of some sentencesDaniel Stenberg
First explain the data then describe what the callback should return.
2014-06-16CURLOPT_WRITEFUNCTION.3: improved languageDaniel Stenberg
Suggestions-by: Jeff Pohlmeyer
2014-06-16CURLOPT_WRITEFUNCTION: add RETURN VALUE and DEFAULT sectionsDaniel Stenberg
2014-06-16CURLOPT_WRITEFUNCTION: initial man pageDaniel Stenberg