cURL / Mailing Lists / curl-library / Single Mail

curl-library

Crashing on curl_easy_cleanup(cur);

From: Ben Helleman <Ben.Helleman_at_adobe.com>
Date: Tue, 15 Oct 2002 07:25:37 -0400

Hi there, I've been having issues when trying to use curl's
curl_easy_cleanup(curl); What has been happening if I execute the
following:
----------------
CURL *curl;
curl = curl_easy_init();
curl_easy_setopt(curl, CURLOPT_URL, url); // url = "http://cnn.com" for
instance
curl_easy_perform(curl);
curl_easy_cleanup(curl); //************************
----------------

the easy_cleanup(curl) crashes my execution. If I remove the
curl_easy_cleanup(curl); line the program runs fine. I thought that each
thread needs to clean itself up, so its best to call curl_easy_cleanup()
after each thread's turn.

Any suggestions what might be going on?

The above snippet of code is located in a function outside of main. In my
main I perform:
curl_global_init(CURL_GLOBAL_WIN32); and after all threads have joined I do
a curl_global_cleanup();

The only thing that I think it might be is that debug version and release
version of libraries?

Suggestions?
Thanks
BH

-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
Received on 2002-10-15