diff --git a/docs/libcurl/opts/CURLOPT_PROGRESSFUNCTION.md b/docs/libcurl/opts/CURLOPT_PROGRESSFUNCTION.md index d9a24382be..eb0981e04f 100644 --- a/docs/libcurl/opts/CURLOPT_PROGRESSFUNCTION.md +++ b/docs/libcurl/opts/CURLOPT_PROGRESSFUNCTION.md @@ -60,11 +60,13 @@ if you only download data, the upload size remains 0). Many times the callback is called one or more times first, before it knows the data sizes so a program must be made to handle that. +Return zero from the callback if everything is fine. + If your callback function returns CURL_PROGRESSFUNC_CONTINUE it causes libcurl to continue executing the default progress function. -Returning any other non-zero value from this callback makes libcurl abort the -transfer and return *CURLE_ABORTED_BY_CALLBACK*. +Return 1 from this callback to make libcurl abort the transfer and return +*CURLE_ABORTED_BY_CALLBACK*. If you transfer data with the multi interface, this function is not called during periods of idleness unless you call the appropriate libcurl function diff --git a/docs/libcurl/opts/CURLOPT_XFERINFOFUNCTION.md b/docs/libcurl/opts/CURLOPT_XFERINFOFUNCTION.md index a7c130a506..e2f95371a1 100644 --- a/docs/libcurl/opts/CURLOPT_XFERINFOFUNCTION.md +++ b/docs/libcurl/opts/CURLOPT_XFERINFOFUNCTION.md @@ -56,12 +56,14 @@ you only download data, the upload size remains 0). Many times the callback is called one or more times first, before it knows the data sizes so a program must be made to handle that. +Return zero from the callback if everything is fine. + +Return 1 from this callback to make libcurl abort the transfer and return +*CURLE_ABORTED_BY_CALLBACK*. + If your callback function returns CURL_PROGRESSFUNC_CONTINUE it makes libcurl to continue executing the default progress function. -Returning any other non-zero value from this callback makes libcurl abort the -transfer and return *CURLE_ABORTED_BY_CALLBACK*. - If you transfer data with the multi interface, this function is not called during periods of idleness unless you call the appropriate libcurl function that performs transfers.