cURL
Haxx ad
libcurl

curl's project page on SourceForge.net

Sponsors:
Haxx

cURL > Mailing List > Monthly Index > Single Mail

curl-library Mailing List Archives

Re: memory leaks in global_init

From: Kamil Dudka <kdudka_at_redhat.com>
Date: Thu, 22 Oct 2009 09:00:23 +0200

On Thursday 22 of October 2009 08:23:04 centrio_at_gmail.com wrote:
> Hi,
> I have a simple main program that is doing following things
>
> #include <iostream>

This ^^^ is redundant.

> #include <curl/curl.h>
>
> using namespace std;

This ^^^ is redundant.

> int main(int argc, char* argv[])
> {
> curl_global_init(CURL_GLOBAL_ALL||CURL_GLOBAL_SSL);
> curl_global_cleanup();
> }
>
> I ran valgrind on this as
> valgrind --tool=memcheck --num-callers=40 --show-reachable=yes
> --leak-check=full sample 2>Valgrind.log
>
> Here is the valgrind log :
>
> ==12093== LEAK SUMMARY:
> ==12093== definitely lost: 0 bytes in 0 blocks.
> ==12093== possibly lost: 0 bytes in 0 blocks.
> ==12093== still reachable: 844 bytes in 11 blocks.
> ==12093== suppressed: 0 bytes in 0 blocks.

Exactly this has been already reported. Nothing bad happens, explained here:

http://permalink.gmane.org/gmane.comp.web.curl.library/24829

> Please let me know if this is a genuine problem, or is there something that
> i am doing wrong.
> My lib versions are
> curl : 7.19.0

Your curl version is not up-to-date.

Kamil
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2009-10-22

These mail archives are generated by hypermail.

donate! Page updated November 12, 2010.
web site info

File upload with ASP.NET