Git init
[external/curl.git] / docs / libcurl / curl_easy_perform.3
1 .\" You can view this file with:
2 .\" nroff -man [file]
3 .\"
4 .TH curl_easy_perform 3 "5 Mar 2001" "libcurl 7.7" "libcurl Manual"
5 .SH NAME
6 curl_easy_perform - Perform a file transfer
7 .SH SYNOPSIS
8 .B #include <curl/curl.h>
9 .sp
10 .BI "CURLcode curl_easy_perform(CURL *" handle ");"
11 .ad
12 .SH DESCRIPTION
13 This function is called after the init and all the \fIcurl_easy_setopt(3)\fP
14 calls are made, and will perform the transfer as described in the options.  It
15 must be called with the same
16 .I handle
17 as input as the curl_easy_init call returned.
18
19 You can do any amount of calls to \fIcurl_easy_perform(3)\fP while using the
20 same handle. If you intend to transfer more than one file, you are even
21 encouraged to do so. libcurl will then attempt to re-use the same connection
22 for the following transfers, thus making the operations faster, less CPU
23 intense and using less network resources. Just note that you will have to use
24 \fIcurl_easy_setopt(3)\fP between the invokes to set options for the following
25 curl_easy_perform.
26
27 You must never call this function simultaneously from two places using the
28 same handle. Let the function return first before invoking it another time. If
29 you want parallel transfers, you must use several curl handles.
30 .SH RETURN VALUE
31 0 means everything was ok, non-zero means an error occurred as
32 .I <curl/curl.h>
33 defines. If the CURLOPT_ERRORBUFFER was set with
34 .I curl_easy_setopt
35 there will be a readable error message in the error buffer when non-zero is
36 returned.
37 .SH "SEE ALSO"
38 .BR curl_easy_init "(3), " curl_easy_setopt "(3), "
39