[Qt-interest] How to debug memory leaks in QT based application?

Nikos Chantziaras realnc at arcor.de
Fri Apr 9 21:02:04 CEST 2010


On 04/09/2010 09:43 PM, Nicolas Rannou wrote:
> On 04/09/2010 02:36 PM, Gabriel M. Beddingfield wrote:
>>
>> On Fri, 9 Apr 2010, Nicolas Rannou wrote:
>>
>>> The problem is that as soon as we use something from QT in our
>>> application, Valgrind reports a lot of memory leaks inside QT (not
>>> related to our application)... So it is almost impossible to find the
>>> leaks I am interested in.
>> Perhaps you can use the --suppress and --gen-suppressions
>> options to suppress errors and libraries that you are not
>> interested in.
>>
>> See /usr/lib/valgrind/default.supp for examples.
>>
>> -gabriel
>
> yes but you have to create the suppressions file manually which I would
> like to avoid....

You can't avoid it since that's how it's designed to work.  Most 
distributions ship pre-generated suppression files though.  Source-based 
distros (like Gentoo) don't bother, so it's up to you on those.



More information about the Qt-interest-old mailing list