[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: lynx-dev Question about --enable-find-leaks

From: Thomas Dickey
Subject: Re: lynx-dev Question about --enable-find-leaks
Date: Wed, 8 Jan 2003 12:33:52 -0500 (EST)

> As suggested by Leonid I added --enable-find-leaks to my
> color-style Cygwin build.
> The question is what happens when a memory leak is found ?

While running, lynx keeps track of all of the allocated memory.  On exit
it walks through the list of chunks that were never freed and writes a
report (Lynx.leaks) to the current directory.  That's useful for some
types of leaks - but some of the reallocations are done at a low-level
by utility functions that don't give much context regarding where the
real allocation was done.  Besides keeping track, lynx also does a little
more work to free up memory that would confuse the reporting (ncurses can
be compiled to provide similar memory-freeing, for this purpose).

Comparable to lynx's built-in checks, one can compile with dmalloc.

Better - to use tools that can show the stack trace for each leak.
Those aren't portable (purify is a commerical tool; valgrind is
a recent tool something like that which runs on linux).

Thomas E. Dickey <address@hidden> <address@hidden>

; To UNSUBSCRIBE: Send "unsubscribe lynx-dev" to address@hidden

reply via email to

[Prev in Thread] Current Thread [Next in Thread]