diff --git a/docs/libcurl/opts/CURLOPT_FTP_FILEMETHOD.md b/docs/libcurl/opts/CURLOPT_FTP_FILEMETHOD.md index 320b362f8f..56b8e3da5a 100644 --- a/docs/libcurl/opts/CURLOPT_FTP_FILEMETHOD.md +++ b/docs/libcurl/opts/CURLOPT_FTP_FILEMETHOD.md @@ -68,8 +68,7 @@ int main(void) if(curl) { CURLcode res; curl_easy_setopt(curl, CURLOPT_URL, "ftp://example.com/1/2/3/4/new.txt"); - curl_easy_setopt(curl, CURLOPT_FTP_FILEMETHOD, - (long)CURLFTPMETHOD_SINGLECWD); + curl_easy_setopt(curl, CURLOPT_FTP_FILEMETHOD, CURLFTPMETHOD_SINGLECWD); res = curl_easy_perform(curl); @@ -78,6 +77,11 @@ int main(void) } ~~~ +# HISTORY + +CURLFTPMETHOD_\* enums became `long` types in 8.16.0, prior to this version +a `long` cast is necessary when passing to curl_easy_setopt(3). + # %AVAILABILITY% # RETURN VALUE