aboutsummaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2014-08-29 08:10:38 +0200
committerDaniel Stenberg <daniel@haxx.se>2014-08-29 08:10:38 +0200
commit367b78473897b6eb72593cd55191077951a69487 (patch)
tree6bb811a5ead94ebe6bd645229192176a32f1f521 /docs
parent7bff23b166b9f3ab1f38d9b289c4e5ed270492da (diff)
curl_formadd.3: setting CURLFORM_CONTENTSLENGTH 0 zero means strlen
Diffstat (limited to 'docs')
-rw-r--r--docs/libcurl/curl_formadd.34
1 files changed, 4 insertions, 0 deletions
diff --git a/docs/libcurl/curl_formadd.3 b/docs/libcurl/curl_formadd.3
index b27e61ddf..3e48149ef 100644
--- a/docs/libcurl/curl_formadd.3
+++ b/docs/libcurl/curl_formadd.3
@@ -86,6 +86,10 @@ you must set its length with \fBCURLFORM_CONTENTSLENGTH\fP.
.IP CURLFORM_CONTENTSLENGTH
followed by a long giving the length of the contents. Note that for
\fICURLFORM_STREAM\fP contents, this option is mandatory.
+
+If you pass a 0 (zero) for this option, libcurl will instead do a strlen() on
+the contents to figure out the size. If you really want to send a zero byte
+content then you must make sure strlen() on the data pointer returns zero.
.IP CURLFORM_FILECONTENT
followed by a filename, causes that file to be read and its contents used
as data in this part. This part does \fInot\fP automatically become a file