curl-library
file size limit upon posting
Date: Thu, 9 Aug 2007 08:01:33 -0700 (PDT)
Hi all. I recently built an app with libcurl 7.15.5. The app was used to transfer files using HTTP and worked just fine.... until I started trying files with sizes approaching 4mb. When I tried transferring files this large, all of a sudden I started getting a return error of CURLE_SEND_ERROR. I was using the form method instead of the upload file method because I also wanted to send other post data. The code is below:
curl_formadd(&formpost,
&lastptr,
CURLFORM_COPYNAME, "sendfile",
CURLFORM_FILE, "myfile.txt",
CURLFORM_END);
curl_formadd(&formpost,
&lastptr,
CURLFORM_COPYNAME, "command",
CURLFORM_COPYCONTENTS, "upload",
CURLFORM_END);
curl_easy_setopt(http_handle, CURLOPT_HTTPPOST, formpost);
I've tried putting the file into a buffer first and using the buffer size options, as well as both postfield size options, nothing works, they all fail when the file size is too large (~4mb). Anyone have any clue as to whats going on here? If I have to use the upload file option, I'd really like send the other post data as well somehow. Thanks.
Rob
____________________________________________________________________________________
Be a better Heartthrob. Get better relationship answers from someone who knows. Yahoo! Answers - Check it out.
http://answers.yahoo.com/dir/?link=list&sid=396545433
Received on 2007-08-09