cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: memory does not freed in windows

From: Meir Yanovich <meiry242_at_gmail.com>
Date: Wed, 15 Oct 2008 08:55:30 +0200

Hello and thanks for the fast reply , im downloading all the web page
content but i do free the string witch
get the content from curl .
one thing i didnt understand is where to use : curl_global_cleanup

On Wed, Oct 15, 2008 at 12:16 AM, Dan Fandrich <dan_at_coneharvesters.com> wrote:
> On Tue, Oct 14, 2008 at 11:14:28PM +0200, Meir Yanovich wrote:
>> Hello all sorry for my bad english
>> im new to curl and im using it in my application to get info from web
>> pages , the thing is
>> im connecting to allot of pages and retrieves information from them .
>> i notice that every time im
>> in the line (part of the curl init as you already know ) :
>> // Attempt to retrieve the remote page
>> result = curl_easy_perform(m_pcurl);
>> i getting another ~500k in the mem usage ( i see it in the windows task bar )
>> that even after im using the command :
>> curl_easy_cleanup(m_pcurl);
>> it cleans me something like ~40k so i left with 450k that keeps added
>> to the memory each time
>> i do request with curl .
>
> curl doesn't even use 500 KB when it's operating, so this memory leak must
> be caused by something else. What is the size of the data that you're
> downloading? Could it be about 450 KB? You don't show all your code,
> but I don't see anywhere that the m_szbuffer member is being freed or
> cleared. You should also call curl_global_cleanup when you're trying to
> find sources of memory usage. Which version of libcurl are you using?
> Memory leaks are occasionally found and fixed in more recent versions.
>
>>>> Dan
> --
> http://www.MoveAnnouncer.com The web change of address service
> Let webmasters know that your web site has moved
>
Received on 2008-10-15