cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: Getting CURLOPT_HTTPHEADER back to normal?

From: Daniel Stenberg <daniel-curl_at_haxx.se>
Date: Wed, 23 Jun 2004 22:33:26 +0200 (CEST)

On Wed, 23 Jun 2004, Casey ODonnell wrote:

> 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?

If it doesn't send any data, it won't use the read function.

> 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.

"inside of fread" ? That would indicate that it tried to read something and
when using the default internal read function it reads from the FILE *
you set with CURLOPT_READDATA. In this case a NULL, which I figure fread
doesn't like.

-- 
      Daniel Stenberg -- http://curl.haxx.se -- http://daniel.haxx.se
       Dedicated custom curl help for hire: http://haxx.se/curl.html
Received on 2004-06-23