]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
docs: POSTFIELDSIZE must be set to -1 with read function
authorDan Fandrich <dan@coneharvesters.com>
Tue, 17 Jan 2023 22:21:07 +0000 (14:21 -0800)
committerDan Fandrich <dan@coneharvesters.com>
Fri, 20 Jan 2023 18:01:43 +0000 (10:01 -0800)
Reported-by: RanBarLavie on github
Closes #10313

docs/libcurl/opts/CURLOPT_POSTFIELDSIZE.3
docs/libcurl/opts/CURLOPT_POSTFIELDSIZE_LARGE.3

index cf6e09a3de91023d362916a55ee872eacf50f521..57ff8f4e4bacee30b7a8546db4a26e76553ca4c6 100644 (file)
@@ -32,10 +32,11 @@ CURLOPT_POSTFIELDSIZE \- size of POST data pointed to
 CURLcode curl_easy_setopt(CURL *handle, CURLOPT_POSTFIELDSIZE, long size);
 .fi
 .SH DESCRIPTION
-If you want to post data to the server without having libcurl do a strlen() to
-measure the data size, this option must be used. When this option is used you
-can post fully binary data, which otherwise is likely to fail. If this size is
-set to -1, the library will use strlen() to get the size.
+If you want to post static data to the server without having libcurl do a
+strlen() to measure the data size, this option must be used. When this option
+is used you can post fully binary data, which otherwise is likely to fail. If
+this size is set to -1, the library will use strlen() to get the size or rely
+on the \fICURLOPT_READFUNCTION\fP (if used) to signal the end of data.
 
 If you post more than 2GB, use \fICURLOPT_POSTFIELDSIZE_LARGE(3)\fP.
 .SH DEFAULT
index 3aac817334337207237a623ff05c1a26bed34ddc..220ba0d3dddecddf40c8fb518134c748ff73f3a0 100644 (file)
@@ -32,10 +32,11 @@ CURLOPT_POSTFIELDSIZE_LARGE \- size of POST data pointed to
 CURLcode curl_easy_setopt(CURL *handle, CURLOPT_POSTFIELDSIZE_LARGE,
                           curl_off_t size);
 .SH DESCRIPTION
-If you want to post data to the server without having libcurl do a strlen() to
-measure the data size, this option must be used. When this option is used you
-can post fully binary data, which otherwise is likely to fail. If this size is
-set to -1, the library will use strlen() to get the size.
+If you want to post static data to the server without having libcurl do a
+strlen() to measure the data size, this option must be used. When this option
+is used you can post fully binary data, which otherwise is likely to fail. If
+this size is set to -1, the library will use strlen() to get the size or rely
+on the \fICURLOPT_READFUNCTION\fP (if used) to signal the end of data.
 .SH DEFAULT
 -1
 .SH PROTOCOLS