summaryrefslogtreecommitdiff
path: root/include/curl
diff options
context:
space:
mode:
authorGokhan Sengun <gokhansengun@gmail.com>2012-06-25 01:46:01 +0300
committerDaniel Stenberg <daniel@haxx.se>2012-08-16 23:20:08 +0200
commit23ef5e4ba22386ccc43f99db1d0f4106dc603e80 (patch)
tree227f78e6398a7a02ad37ddd050ee965b4d77a4f5 /include/curl
parent44154e0733c2b6fcadaaf772dfd5c93792fb07cc (diff)
downloadcurl-23ef5e4ba22386ccc43f99db1d0f4106dc603e80.tar.gz
ftp: active conn, allow application to set sockopt after accept() call
For active FTP connections, applications may need setting the sockopt after accept() call returns successful. This fix gives a call to the callback registered with CURL_SOCKOPTFUNCTION option. Also a new sock type - CURLSOCKTYPE_ACCEPT - is added. This type is to be passed to application callbacks with - purpose - parameter. Applications may use this parameter to distinguish between socket types.
Diffstat (limited to 'include/curl')
-rw-r--r--include/curl/curl.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/include/curl/curl.h b/include/curl/curl.h
index 46ccf164b..200188d91 100644
--- a/include/curl/curl.h
+++ b/include/curl/curl.h
@@ -309,8 +309,9 @@ typedef size_t (*curl_read_callback)(char *buffer,
void *instream);
typedef enum {
- CURLSOCKTYPE_IPCXN, /* socket created for a specific IP connection */
- CURLSOCKTYPE_LAST /* never use */
+ CURLSOCKTYPE_IPCXN, /* socket created for a specific IP connection */
+ CURLSOCKTYPE_ACCEPT, /* socket created by accept() call */
+ CURLSOCKTYPE_LAST /* never use */
} curlsocktype;
/* The return code from the sockopt_callback can signal information back