Updated cURL version.

This commit is contained in:
Asher Baker
2013-03-17 22:23:20 +00:00
parent 986aa2a477
commit 63175aa3cb
1510 changed files with 213259 additions and 161405 deletions
@@ -1,6 +1,8 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html><head>
<title>curl_formget man page</title>
<meta name="generator" content="roffit 0.7">
<meta name="generator" content="roffit">
<STYLE type="text/css">
P.level0 {
padding-left: 2em;
@@ -44,36 +46,19 @@ p.roffit {
</head><body>
<p class="level0"><a name="NAME"></a><h2 class="nroffsh">NAME</h2>
<p class="level0">curl_formget - serialize a previously build multipart/formdata HTTP POST chain <a name="SYNOPSIS"></a><h2 class="nroffsh">SYNOPSIS</h2>
<p class="level0">curl_formget - serialize a previously built multipart/formdata HTTP POST chain <a name="SYNOPSIS"></a><h2 class="nroffsh">SYNOPSIS</h2>
<p class="level0">
<p class="level0"><span Class="bold">#include &lt;curl/curl.h&gt;</span>
<p class="level0"><span Class="bold">void curl_formget(struct curl_httppost * form, void * arg,</span> <span Class="bold"> curl_formget_callback append );</span>
<p class="level0"><a name="DESCRIPTION"></a><h2 class="nroffsh">DESCRIPTION</h2>
<p class="level0">curl_formget() is used to serialize data previously built/appended with <a class="emphasis" href="./curl_formadd.html">curl_formadd(3)</a>. Accepts a void pointer as second argument which will be passed to the curl_formget_callback function.
<p class="level0"><span Class="bold">typedef size_t (*curl_formget_callback)(void * arg, const char * buf,</span> <span Class="bold"> size_t len );</span> <pre>
<p class="level0"><p class="level0">The curl_formget_callback will be executed for each part of the HTTP POST
chain. The void *arg pointer will be the one passed as second argument to
curl_formget(). The character buffer passed to it must not be freed. The
callback should return the buffer length passed to it on success.
</pre>
<a name="RETURN"></a><h2 class="nroffsh">RETURN VALUE</h2>
<p class="level0">void curl_formget(struct curl_httppost * form, void *userp, &nbsp; curl_formget_callback append ); <a name="DESCRIPTION"></a><h2 class="nroffsh">DESCRIPTION</h2>
<p class="level0">curl_formget() is used to serialize data previously built/appended with <a class="emphasis" href="./curl_formadd.html">curl_formadd(3)</a>. Accepts a void pointer as second argument named <span Class="emphasis">userp</span> which will be passed as the first argument to the curl_formget_callback function.
<p class="level0"><span Class="bold">typedef size_t (*curl_formget_callback)(void * userp, const char * buf,</span> <span Class="bold"> size_t len );</span>
<p class="level0">The curl_formget_callback will be executed for each part of the HTTP POST chain. The character buffer passed to the callback must not be freed. The callback should return the buffer length passed to it on success.
<p class="level0">If the <span Class="bold">CURLFORM_STREAM</span> option is used in the formpost, it will prevent <a class="emphasis" href="./curl_formget.html">curl_formget(3)</a> from working until you've performed the actual HTTP request as only then will libcurl get the actual read callback to use! <a name="RETURN"></a><h2 class="nroffsh">RETURN VALUE</h2>
<p class="level0">0 means everything was ok, non-zero means an error occurred <a name="EXAMPLE"></a><h2 class="nroffsh">EXAMPLE</h2>
<p class="level0"><pre>
<p class="level0"><p class="level0">&nbsp;size_t print_httppost_callback(void *arg, const char *buf, size_t len)
&nbsp;{
&nbsp; fwrite(buf, len, 1, stdout);
&nbsp; (*(size_t *) arg) += len;
&nbsp; return len;
&nbsp;}
&nbsp;size_t print_httppost(struct curl_httppost *post)
&nbsp;{
&nbsp; size_t total_size = 0;
&nbsp; if(curl_formget(post, &total_size, print_httppost_callback)) {
&nbsp; return (size_t) -1;
&nbsp; }
&nbsp; return total_size;
&nbsp;}
</pre>
<a name="AVAILABILITY"></a><h2 class="nroffsh">AVAILABILITY</h2>
<p class="level0">
<p class="level0">
<p class="level0">&nbsp;size_t print_httppost_callback(void *arg, const char *buf, size_t len) &nbsp;{ &nbsp; fwrite(buf, len, 1, stdout); &nbsp; (*(size_t *) arg) += len; &nbsp; return len; &nbsp;}
<p class="level0">&nbsp;size_t print_httppost(struct curl_httppost *post) &nbsp;{ &nbsp; size_t total_size = 0; &nbsp; if(curl_formget(post, &total_size, print_httppost_callback)) { &nbsp; return (size_t) -1; &nbsp; } &nbsp; return total_size; &nbsp;} <a name="AVAILABILITY"></a><h2 class="nroffsh">AVAILABILITY</h2>
<p class="level0">This function was added in libcurl 7.15.5 <a name="SEE"></a><h2 class="nroffsh">SEE ALSO</h2>
<p class="level0"><a class="manpage" href="./curl_formadd.html">curl_formadd (3) </a> <p class="roffit">
This HTML page was made with <a href="http://daniel.haxx.se/projects/roffit/">roffit</a>.