|
|
cURL Mailing List Monthly Index Single Mail
curl-library Archives
RE: Put request with postfields libcurl c++
From: Zaid Amir <z.alamir_at_genie-soft.com>
Date: Tue, 10 Nov 2009 12:08:24 +0200
-----Original Message-----
On Mon, 2 Nov 2009, Zaid Amir wrote:
> size_t readTextCallback(void* ptr,size_t size, size_t nmemb, void* stream)
> string* strptrdst = static_cast<string*>(ptr);
Don't get sucked up by all the fancy C++isms you can make in a program. Try
The read callback is supposed to copy data to the buffer, data that libcurl
'ptr' points to the buffer. size*nmemb is the (maximum) amount of data you
Just copy data to the buffer in every invoke until there is no more data to
A slightly different way to do PUT with a fixed string, is to instead: use
-- / daniel.haxx.se ------------------------------------------------------------------- List admin: http://cool.haxx.se/list/listinfo/curl-library Etiquette: http://curl.haxx.se/mail/etiquette.html Neither one of the methods you provided worked, The problem is that when using CUSTOMREQUEST and POSTFIELDS the connection hangs. I am still not sure how I'm supposed to issue a PUT request with a message body in curl... its been days now and I'm still at point zero. ------------------------------------------------------------------- List admin: http://cool.haxx.se/list/listinfo/curl-library Etiquette: http://curl.haxx.se/mail/etiquette.htmlReceived on 2009-11-10 These mail archives are generated by hypermail. |
Page updated November 16, 2009.
web site info