Re: curl_easy_cleanup question
Date: Fri, 24 Sep 2004 08:07:37 +0200 (CEST)
On Thu, 23 Sep 2004, Tarendash, David wrote:
> Has anyone had problems with curl_easy_cleanup() ??? For some reason it is
> coring on my RH-AS-3.0 box. I understand that my explanation is vague, but,
> I cant reproduce it, it just periodically happens. I've run top and other ps
> commands, and the system seems to be stable(ie not out of memory). If you
> notice, the pointer being passed into curl_easy_cleanup() appears to be a
> valid one.
You forgot to mention what versions of libcurl and OpenSSL you're using.
> #0 0xb6fdbcb0 in _int_free () from /lib/tls/libc.so.6
> #1 0xb6fdac88 in free () from /lib/tls/libc.so.6
> #2 0xb6e6fe0d in CRYPTO_free () from /lib/libcrypto.so.4
> #3 0xb6eaeca9 in BUF_MEM_free () from /lib/libcrypto.so.4
This is clearly a crash in OpenSSL. It might be because your program has
overwritten some memory in a previous call.
I recommend using valgrind to track this down. I don't believe this is a
> I have a process which will be making a single request over and over
> (different data in the post). Should I be using a single CURL* object (ie
> call init() once and never call cleanup()) ?
Yes, that's the recommended way.
> I have tried this and the memory leakage growth is HUGE...
Then please give us details on that, as that would indicate a huge bug. I
actually think you're wrong, since many people use libcurl this way without
seeing such leaks.
-- Daniel Stenberg -- http://curl.haxx.se -- http://daniel.haxx.se Dedicated custom curl help for hire: http://haxx.se/curl.htmlReceived on 2004-09-24