aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2011-03-29 11:19:49 +0200
committerDaniel Stenberg <daniel@haxx.se>2011-03-29 11:19:49 +0200
commit2a0c7ea4cc94a01c9396a213b2d0ccce6c05b37f (patch)
tree86c6e8372a5114b4e2c73311b23c07694145c222
parent4913a08cb6cfe653b1b2ee6c6dacb9408e9be4f0 (diff)
curl_easy_setopt.3: mention TFTP read callback flaw
The read callback must return the exact requested amount of data when it is used for doing TFTP uploads. This is due to how it deals with data internally. This could/should be fixed but for now we document the existing behavior. Reported by: Colin Blair Bug: http://curl.haxx.se/mail/lib-2011-03/0319.html
-rw-r--r--docs/libcurl/curl_easy_setopt.34
1 files changed, 4 insertions, 0 deletions
diff --git a/docs/libcurl/curl_easy_setopt.3 b/docs/libcurl/curl_easy_setopt.3
index 6166d5fd5..16f4b5842 100644
--- a/docs/libcurl/curl_easy_setopt.3
+++ b/docs/libcurl/curl_easy_setopt.3
@@ -208,6 +208,10 @@ From 7.18.0, the function can return CURL_READFUNC_PAUSE which then will cause
reading from this connection to become paused. See \fIcurl_easy_pause(3)\fP
for further details.
+\fBBugs\fP: when doing TFTP uploads, you must return the exact amount of data
+that the callback wants, or it will be considered the final packet by the
+server end and the transfer will end there.
+
If you set this callback pointer to NULL, or don't set it at all, the default
internal read function will be used. It is doing an fread() on the FILE *
userdata set with \fICURLOPT_READDATA\fP.