NetBSD-Users archive

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

Re: debugging a memory leak



On Sat, May 21, 2016 at 10:10:03AM +0200, Manuel Bouyer wrote:
> On Sat, May 21, 2016 at 08:36:10AM +0200, tlaronde%polynum.com@localhost wrote:
> > On Fri, May 20, 2016 at 11:43:11PM +0200, Manuel Bouyer wrote:
> > > On Fri, May 20, 2016 at 02:20:39PM -0600, Swift Griggs wrote:
> > > > On Fri, 20 May 2016, Manuel Bouyer wrote:
> > > > > what tools do we have on NetBSD to find a memory leak in a userland 
> > > > > program (actually OpenCPN - which is a large C++ program with dynamic 
> > > > > libraries and uses dlopen()) ?
> > > > 
> > 
> > I have used boehm-gc in the past on NetBSD. It is a garbage collector
> > and allows to spot memory leaks too. It's in pkgsrc.
> 
> thanks for the pointer. But if I understood it properly, the sources
> needs to be modified ? I fear that in my case this is not an option:
> opencpn is quite large and uses wxwidgets and glib, the memory may
> be allocated from here too ...

Yep, this is the problem: all sources (where the problem is suspected to
lie) have to be recompiled against this implementation of malloc and 
co... 
-- 
        Thierry Laronde <tlaronde +AT+ polynum +dot+ com>
                     http://www.kergis.com/
                     http://www.arts-po.fr/
Key fingerprint = 0FF7 E906 FBAF FE95 FD89  250D 52B1 AE95 6006 F40C


Home | Main Index | Thread Index | Old Index