Lines Matching refs:curlhandle
70 static int upload(CURL *curlhandle, const char *remotepath,
84 curl_easy_setopt(curlhandle, CURLOPT_UPLOAD, 1L);
86 curl_easy_setopt(curlhandle, CURLOPT_URL, remotepath);
89 curl_easy_setopt(curlhandle, CURLOPT_SERVER_RESPONSE_TIMEOUT, timeout);
91 curl_easy_setopt(curlhandle, CURLOPT_HEADERFUNCTION, getcontentlengthfunc);
92 curl_easy_setopt(curlhandle, CURLOPT_HEADERDATA, &uploaded_len);
94 curl_easy_setopt(curlhandle, CURLOPT_WRITEFUNCTION, discardfunc);
96 curl_easy_setopt(curlhandle, CURLOPT_READFUNCTION, readfunc);
97 curl_easy_setopt(curlhandle, CURLOPT_READDATA, f);
100 curl_easy_setopt(curlhandle, CURLOPT_FTPPORT, "-");
103 curl_easy_setopt(curlhandle, CURLOPT_ACCEPTTIMEOUT_MS, 7000L);
105 curl_easy_setopt(curlhandle, CURLOPT_FTP_CREATE_MISSING_DIRS, 1L);
107 curl_easy_setopt(curlhandle, CURLOPT_VERBOSE, 1L);
122 curl_easy_setopt(curlhandle, CURLOPT_NOBODY, 1L);
123 curl_easy_setopt(curlhandle, CURLOPT_HEADER, 1L);
125 r = curl_easy_perform(curlhandle);
129 curl_easy_setopt(curlhandle, CURLOPT_NOBODY, 0L);
130 curl_easy_setopt(curlhandle, CURLOPT_HEADER, 0L);
134 curl_easy_setopt(curlhandle, CURLOPT_APPEND, 1L);
137 curl_easy_setopt(curlhandle, CURLOPT_APPEND, 0L);
140 r = curl_easy_perform(curlhandle);
155 CURL *curlhandle = NULL;
158 curlhandle = curl_easy_init();
160 upload(curlhandle, "ftp://user:pass@example.com/path/file", "C:\\file",
163 curl_easy_cleanup(curlhandle);