瀏覽代碼

curl_easy_getinfo: clarify on return data types

Closes #11126
Hind Montassif 1 年之前
父節點
當前提交
de522c55ba
共有 2 個文件被更改,包括 12 次插入13 次删除
  1. 5 6
      docs/libcurl/curl_easy_getinfo.3
  2. 7 7
      include/curl/easy.h

+ 5 - 6
docs/libcurl/curl_easy_getinfo.3

@@ -33,12 +33,11 @@ CURLcode curl_easy_getinfo(CURL *curl, CURLINFO info, ... );
 .fi
 .SH DESCRIPTION
 Request internal information from the curl session with this function. The
-third argument \fBMUST\fP be a pointer to a long, a pointer to a char *, a
-pointer to a struct curl_slist * or a pointer to a double (as this
-documentation describes further down). The data pointed-to will be filled in
-accordingly and can be relied upon only if the function returns CURLE_OK. Use
-this function AFTER a performed transfer if you want to get transfer related
-data.
+third argument \fBMUST\fP be pointing to the specific type of the used option
+which is documented in each man page of the option. The data pointed-to will
+be filled in accordingly and can be relied upon only if the function returns
+CURLE_OK. Use this function AFTER a performed transfer if you want to get
+transfer related data.
 
 You should not free the memory returned by this function unless it is
 explicitly mentioned below.

+ 7 - 7
include/curl/easy.h

@@ -48,13 +48,13 @@ CURL_EXTERN void curl_easy_cleanup(CURL *curl);
  *
  * DESCRIPTION
  *
- * Request internal information from the curl session with this function.  The
- * third argument MUST be a pointer to a long, a pointer to a char * or a
- * pointer to a double (as the documentation describes elsewhere).  The data
- * pointed to will be filled in accordingly and can be relied upon only if the
- * function returns CURLE_OK.  This function is intended to get used *AFTER* a
- * performed transfer, all results from this function are undefined until the
- * transfer is completed.
+ * Request internal information from the curl session with this function.
+ * The third argument MUST be pointing to the specific type of the used option
+ * which is documented in each man page of the option. The data pointed to
+ * will be filled in accordingly and can be relied upon only if the function
+ * returns CURLE_OK. This function is intended to get used *AFTER* a performed
+ * transfer, all results from this function are undefined until the transfer
+ * is completed.
  */
 CURL_EXTERN CURLcode curl_easy_getinfo(CURL *curl, CURLINFO info, ...);