cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: Proposed fix for OpenSSL memory leaks.

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Thu, 10 May 2012 13:10:02 +0200 (CEST)

On Thu, 10 May 2012, Mischa Salle wrote:

> The real problem emerges if you use both curl+openssl *and* openssl
> directly, then you can just hope that the cleanup functions put the pointers
> to NULL to prevent double free()'s...

I believe this is generally safe with modern OpenSSL versions.

> Concerning the init: in principle the curl_global_init is called
> automatically by the curl_easy_init if you don't do it explicitly (if I'm
> not mistaken).

That is correct. But as curl_global_init() isn't thread safe etc, letting your
program depend on the "automatic" init might not be the wisest idea.

-- 
  / daniel.haxx.se
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette:  http://curl.haxx.se/mail/etiquette.html
Received on 2012-05-10