curl/lib
2003-06-26 11:31:50 +00:00
..
.cvsignore
arpa_telnet.h
base64.c
base64.h
ca-bundle.crt
ca-bundle.h.in
config-mac.h
config-riscos.h
config-vms.h
config-win32.h
config.dj
connect.c
connect.h
content_encoding.c
content_encoding.h
cookie.c
cookie.h
curllib.dsp
curllib.dsw
dict.c
dict.h
easy.c
escape.c
escape.h
file.c
file.h
formdata.c use CURLDEBUG instead of MALLOCDEBUG for preprocessor conditions 2003-06-26 11:22:12 +00:00
formdata.h
ftp.c
ftp.h
getdate.c.cvs
getdate.h Nico Baggus' VMS tweaks 2002-02-20 13:46:53 +00:00
getdate.y
getenv.c use CURLDEBUG instead of MALLOCDEBUG for preprocessor conditions 2003-06-26 11:22:12 +00:00
getinfo.c use CURLDEBUG instead of MALLOCDEBUG for preprocessor conditions 2003-06-26 11:22:12 +00:00
getinfo.h
getpass.c use CURLDEBUG instead of MALLOCDEBUG for preprocessor conditions 2003-06-26 11:22:12 +00:00
getpass.h
hash.c use CURLDEBUG instead of MALLOCDEBUG for preprocessor conditions 2003-06-26 11:22:12 +00:00
hash.h
hostip.c use CURLDEBUG instead of MALLOCDEBUG for preprocessor conditions 2003-06-26 11:22:12 +00:00
hostip.h use CURLDEBUG instead of MALLOCDEBUG for preprocessor conditions 2003-06-26 11:22:12 +00:00
http_chunks.c use CURLDEBUG instead of MALLOCDEBUG for preprocessor conditions 2003-06-26 11:22:12 +00:00
http_chunks.h
http_digest.c use CURLDEBUG instead of MALLOCDEBUG for preprocessor conditions 2003-06-26 11:22:12 +00:00
http_digest.h
http_negotiate.c kill warnings 2003-06-26 11:25:23 +00:00
http_negotiate.h new proto for Curl_input_negotiate 2003-06-26 11:25:42 +00:00
http_ntlm.c Many fixes, most of them based on comments by Eric Glass 2003-06-26 11:26:26 +00:00
http_ntlm.h added ntlm flag bits 2003-06-26 11:26:50 +00:00
http.c major adjustments to the new authentication support 2003-06-26 11:24:55 +00:00
http.h
if2ip.c use CURLDEBUG instead of MALLOCDEBUG for preprocessor conditions 2003-06-26 11:22:12 +00:00
if2ip.h
inet_ntoa_r.h
krb4.c use CURLDEBUG instead of MALLOCDEBUG for preprocessor conditions 2003-06-26 11:22:12 +00:00
krb4.h
ldap.c
ldap.h
libcurl.def Dave Halbakken added curl_version_info 2002-11-11 21:57:14 +00:00
llist.c use CURLDEBUG instead of MALLOCDEBUG for preprocessor conditions 2003-06-26 11:22:12 +00:00
llist.h
Makefile.am Initial take at NTLM authentication. It doesn't really work at this point 2003-06-11 13:38:55 +00:00
Makefile.b32
Makefile.b32.resp
makefile.dj
Makefile.m32
Makefile.riscos
Makefile.vc6
md5.c adjusted to use the same API as the OpenSSL version of the MD5 functions 2003-06-26 11:27:22 +00:00
md5.h
memdebug.c use CURLDEBUG instead of MALLOCDEBUG for preprocessor conditions 2003-06-26 11:22:12 +00:00
memdebug.h use CURLDEBUG 2003-06-26 11:27:38 +00:00
mprintf.c use CURLDEBUG instead of MALLOCDEBUG for preprocessor conditions 2003-06-26 11:22:12 +00:00
multi.c use CURLDEBUG instead of MALLOCDEBUG for preprocessor conditions 2003-06-26 11:22:12 +00:00
netrc.c use CURLDEBUG instead of MALLOCDEBUG for preprocessor conditions 2003-06-26 11:22:12 +00:00
netrc.h
progress.c
progress.h
README.encoding
README.memoryleak the malloc debug system assumes single thread 2002-10-28 21:05:14 +00:00
security.c use CURLDEBUG instead of MALLOCDEBUG for preprocessor conditions 2003-06-26 11:22:12 +00:00
security.h
sendf.c use CURLDEBUG instead of MALLOCDEBUG for preprocessor conditions 2003-06-26 11:22:12 +00:00
sendf.h
setup.h
share.c use CURLDEBUG instead of MALLOCDEBUG 2003-06-26 11:28:26 +00:00
share.h
speedcheck.c
speedcheck.h
ssluse.c use CURLDEBUG instead of MALLOCDEBUG for preprocessor conditions 2003-06-26 11:22:12 +00:00
ssluse.h
strequal.c
strequal.h
strtok.c
strtok.h
telnet.c use CURLDEBUG instead of MALLOCDEBUG for preprocessor conditions 2003-06-26 11:22:12 +00:00
telnet.h
timeval.c removed the local variables for emacs and vim, use the new sample.emacs 2003-01-29 10:14:20 +00:00
timeval.h
transfer.c Adjusted to work properly with the new authentication stuff 2003-06-26 11:30:26 +00:00
transfer.h
url.c added CURLOPT_HTTPAUTH support 2003-06-26 11:30:59 +00:00
url.h
urldata.h new httpauth support, changed filetime variable kind 2003-06-26 11:31:50 +00:00
version.c include GSS in the debug string if available, support a few new flag 2003-06-26 11:22:48 +00:00

$Id$
                                  _   _ ____  _     
                              ___| | | |  _ \| |    
                             / __| | | | |_) | |    
                            | (__| |_| |  _ <| |___ 
                             \___|\___/|_| \_\_____|

             How To Track Down Suspected Memory Leaks in libcurl
             ===================================================

Single-threaded

  Please note that this memory leak system is not adjusted to work in more
  than one thread. If you want/need to use it in a multi-threaded app. Please
  adjust accordingly.


Build

  Rebuild libcurl with -DMALLOCDEBUG (usually, rerunning configure with
  --enable-debug fixes this). 'make clean' first, then 'make' so that all
  files actually are rebuilt properly. It will also make sense to build
  libcurl with the debug option (usually -g to the compiler) so that debugging
  it will be easier if you actually do find a leak in the library.

  This will create a library that has memory debugging enabled.

Modify Your Application

  Add a line in your application code:

       curl_memdebug("filename");

  This will make the malloc debug system output a full trace of all resource
  using functions to the given file name. Make sure you rebuild your program
  and that you link with the same libcurl you built for this purpose as
  described above.

Run Your Application

  Run your program as usual. Watch the specified memory trace file grow.

  Make your program exit and use the proper libcurl cleanup functions etc. So
  that all non-leaks are returned/freed properly.

Analyze the Flow

  Use the tests/memanalyze.pl perl script to analyze the memdump file:

    tests/memanalyze.pl < memdump

  This now outputs a report on what resources that were allocated but never
  freed etc. This report is very fine for posting to the list!

  If this doesn't produce any output, no leak was detected in libcurl. Then
  the leak is mostly likely to be in your code.