cURL / Mailing Lists / curl-library / Single Mail


Re: memory leak -

From: Dan Fandrich <>
Date: Wed, 20 Aug 2008 12:17:57 -0700

On Wed, Aug 20, 2008 at 08:26:21AM -0700, Phil Pellouchoud wrote:
> I noticed a memory leak after making an HTTPS call. After some amount
> of digging, I found that the last function CRYPTO_cleanup_all_ex_data()
> was not getting called (i.e. it was effectively not compiled in). If I
> put a call to that after curl_global_cleanup(), I noticed that the
> memory leak went away. This lead me to believe that I should have had
> HAVE_CRYPTO_CLEANUP_ALL_EX_DATA defined. I searched for that constant
> and only found it in config-tpf.h and config-symbian.h (which had it
> commented out). I'm guessing that should be defined in config-win32.h,
> but I'd like some guidance here; like possibly if I'm doing something
> wrong or doing it the wrong way...

The HAVE_CRYPTO_CLEANUP_ALL_EX_DATA macro is set by autoconf whenever it's
available in the OpenSSL lib. Since Windows' config.h isn't created
automatically, it will probably have to be added manually. Maybe it should
be set by default in config-win32.h and a note added to the INSTALL file to
comment it out when using an old OpenSSL.

>>> Dan

--              The web change of address service
          Let webmasters know that your web site has moved
Received on 2008-08-20