cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re[2]: memory leak or my error?

From: Paul Accosta <paco_at_hungary.cc>
Date: Fri, 30 May 2003 02:56:05 +0200

Actually Im not sure why this worked but I tried what RBramante_at_on.com
had posted earlier about doing the curl_global_cleanup and it solved my
memory issue. I guess this might add a little overhead of processor time
since each use will now be initialized then freed but Ive had my program
running for a few hours now and the memory is stable compared to the
high climbs I got without this. Weird but it worked.

Thanks All.
Paco

Dan Fandrich <dan_at_coneharvesters.com> wrote:

>On Thu, May 29, 2003 at 09:10:46PM +0200, Paul Accosta wrote:
> > Im basically just doing a get of a webpage, its boils donw to 4
basic
> > calls:
> >
> > curl = curl_easy_init();
> > curl_easy_setopt(curl, CURLOPT_URL, dst_str);
> > res = curl_easy_perform(curl);
> > curl_easy_cleanup(curl);
> >
> > Ive noticed my memory keeps rising, I monitored it carefully and
> notice
> > that it rises significantly with the perform call and never drops
back
> > down. Is there something else I need to do to fix this?
>
> Some malloc implementations don't release memory back to the kernel
> right
> away but keep it allocated for future use. Are you sure what you're
> seeing isn't an artifact of your dynamic memory allocator?
>
> > Paco
> >
> > ps.Thanks for all the help last time, your ideas worked for me
>
> >>> Dan
> --
> http://www.MoveAnnouncer.com The web change of address
> service
> Let webmasters know that your web site has moved
>
>
> -------------------------------------------------------
> This SF.net email is sponsored by: eBay
> Get office equipment for less on eBay!
> http://adfarm.mediaplex.com/ad/ck/711-11697-6916-5
>
>
>
---------------------------------------

-------------------------------------------------------
This SF.net email is sponsored by: eBay
Get office equipment for less on eBay!
http://adfarm.mediaplex.com/ad/ck/711-11697-6916-5
Received on 2003-05-30