curl-library
Re: Getting CURLOPT_HTTPHEADER back to normal?
Date: Wed, 23 Jun 2004 16:03:24 -0400
Awesome...
Thank you. I have another question though. Similar in nature. I'm
using MS Windows with the DLL (latest version of LibCURL).
I'm performing one call that uses:
curl_easy_setopt(m_pCURL, CURLOPT_READFUNCTION, wxcurldav_str_read);
curl_easy_setopt(m_pCURL, CURLOPT_READDATA, (void*)&szXmlStr);
Which works fine. My app is uploading some XML to go along with the
request. However, when I perform another call that doesn't need to
send any data, how do I tell the library to ignore the read function
now? The code I've got for the other operations work fine, as long as
I don't re-use my CURL* handle.
I've tried:
curl_easy_setopt(m_pCURL, CURLOPT_READFUNCTION, NULL);
curl_easy_setopt(m_pCURL, CURLOPT_READDATA, NULL);
But that causes a crash in NTDLL.DLL inside of fread, so I suspect
that I'm doing something bad. I'm basically trying to restore the
initialized state of my CURL* handle, without loosing the performance
boost I get by keeping it around.
Thanks again. Hope this isn't too newbie-ish.
CKO
> Set it to NULL:
>
> curl_easy_setopt(handle, CURLOPT_HTTPHEADER, NULL);
Received on 2004-06-23