curl-library
Re: libcurl memleak
Date: Mon, 28 Oct 2002 16:26:04 -0500
I guess the memdebug stuff isn't installed with the debug library. Because
linking against the library in the curl source tree worked without the
unresolved symbol. I reran my program single threaded and the analysis
looks much more sane although it's still huge. Here's a snippet from the
beginning (all looks that same):
Leak detected: memory still allocated: 845600 bytes
At 80f0074, there's 160 bytes.
allocated by hostip.c:534
At 806d514, there's 160 bytes.
allocated by hostip.c:534
At 8115cc4, there's 160 bytes.
allocated by hostip.c:534
At 8081624, there's 160 bytes.
allocated by hostip.c:534
At 806e174, there's 160 bytes.
allocated by hostip.c:534
At 8082284, there's 160 bytes.
allocated by hostip.c:534
At 80b2114, there's 160 bytes.
allocated by hostip.c:534
At 814a224, there's 160 bytes.
allocated by hostip.c:534
At 80cc7e4, there's 160 bytes.
allocated by hostip.c:534
At 80e08f4, there's 160 bytes.
allocated by hostip.c:534
At 80e5544, there's 160 bytes.
allocated by hostip.c:534
At 8121034, there's 160 bytes.
allocated by hostip.c:534
At 80bef54, there's 160 bytes.
allocated by hostip.c:534
At 8077754, there's 160 bytes.
allocated by hostip.c:534
At 80a35f4, there's 160 bytes.
allocated by hostip.c:534
At 808fbc4, there's 160 bytes.
allocated by hostip.c:534
At 80a8244, there's 160 bytes.
allocated by hostip.c:534
At 81118b4, there's 160 bytes.
allocated by hostip.c:534
At 812de74, there's 160 bytes.
allocated by hostip.c:534
and it continues.
Avery Fay
Daniel Stenberg
<daniel_at_haxx.se> To: libcurl Mailing list <curl-library_at_lists.sourceforge.net>
Sent by: cc:
curl-library-admin_at_lists.sour Subject: Re: libcurl memleak
ceforge.net
10/28/2002 04:03 PM
Please respond to
curl-library
On Mon, 28 Oct 2002, Avery Fay wrote:
> Recompiled my program using the curl_memdebug call. I found that the
> library installed with make install did not include this call so I linked
> my program against memdebug.o from the curl source tree. Is this correct?
Hm, no, it's not meant to need any extra kludge like that. Personally, I
never actually install the debug library though...
> After running my program, I analyzed the dump and here is the beginning
> (too big to send to list):
[cut out]
> It looks like some of the lines got corrupted. Maybe is writing to this
> file not serialized? My program is multithreaded.
Oh, right! I should add that to the memleak readme. It has no means at all
to
deal with that. I'd suggest you either run your app in a single thread or
you
patch up memdebug.c to not write to the file from more than one thread at a
time.
-- Daniel Stenberg -- curl, cURL, Curl, CURL. Groks URLs. ------------------------------------------------------- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf ------------------------------------------------------- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sfReceived on 2002-10-28