Fri, Mar 04, 2011 at 10:02:45PM -0600, Eric Anderson wrote: > I have a moderately threaded userland program (all C) I am working > on (using pthreads, freebsd 8.1 64bit). It seems to leak memory > (using standard malloc/free) badly. I am using pcap to capture > packets and process them. I have a handful of libs statically linked > in (pcap is one, the rest don't seem to matter - I can remove them > and still see the leak). > > Does anyone know of issues regarding malloc/free on multithreaded > userland apps?
I personally hadn't heard about them, but you can definitely run your program under Valgrind's memcheck tool -- it often does the good amount of work and detects many leaks. Valrgind is ported to FreeBSD, devel/valgrind. -- Eygene Ryabinkin ,,,^..^,,, [ Life's unfair - but root password helps! | codelabs.ru ] [ 82FE 06BC D497 C0DE 49EC 4FF0 16AF 9EAE 8152 ECFB | freebsd.org ]
pgpOEzCdUHTI2.pgp
Description: PGP signature