From 5acadc9cd7a1ff40ffa8d57214c90d8c788b2b03 Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Tue, 29 Aug 2006 14:39:33 +0000 Subject: David McCreedy added CURLOPT_SOCKOPTFUNCTION and CURLOPT_SOCKOPTDATA to allow applications to set their own socket options. --- docs/libcurl/curl_easy_setopt.3 | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) (limited to 'docs') diff --git a/docs/libcurl/curl_easy_setopt.3 b/docs/libcurl/curl_easy_setopt.3 index 0fce61a98..98abd417d 100644 --- a/docs/libcurl/curl_easy_setopt.3 +++ b/docs/libcurl/curl_easy_setopt.3 @@ -160,12 +160,28 @@ found in \fI\fP. This function gets called by libcurl when something special I/O-related needs to be done that the library can't do by itself. For now, rewinding the read data stream is the only action it can request. The rewinding of the read data stream may be necessary when doing a -HTTP PUT or POST with a multi-pass authentication method. (Opion added in +HTTP PUT or POST with a multi-pass authentication method. (Option added in 7.12.3) .IP CURLOPT_IOCTLDATA Pass a pointer that will be untouched by libcurl and passed as the 3rd argument in the ioctl callback set with \fICURLOPT_IOCTLFUNCTION\fP. (Option added in 7.12.3) +.IP CURLOPT_SOCKOPTFUNCTION +Function pointer that should match the \fIcurl_sockopt_callback\fP prototype +found in \fI\fP. This function gets called by libcurl after the +socket() call but before the connect() call. The callback's \fIpurpose\fP +argument identifies the exact purpose for this particular socket, and +currently only one value is supported: \fICURLSOCKTYPE_IPCXN\fP for the +primary connection (meaning the control connection in the FTP case). Future +versions of libcurl may support more purposes. It passes the newly created +socket descriptor so additional setsockopt() calls can be done at the user's +discretion. A non-zero return code from the callback function will signal an +unrecoverable error to the library and it will close the socket and return +\fICURLE_COULDNT_CONNECT\fP. (Option added in 7.15.6.) +.IP CURLOPT_SOCKOPTDATA +Pass a pointer that will be untouched by libcurl and passed as the first +argument in the sockopt callback set with \fICURLOPT_SOCKOPTFUNCTION\fP. +(Option added in 7.15.6.) .IP CURLOPT_PROGRESSFUNCTION Function pointer that should match the \fIcurl_progress_callback\fP prototype found in \fI\fP. This function gets called by libcurl instead of -- cgit v1.2.3