[Digikam-devel] Re: memory leak in trunk...

Marcel Wiesweg marcel.wiesweg at gmx.de
Tue Nov 30 17:04:42 GMT 2010


> 7,413 ==1995==    at 0x40244F0: operator new(unsigned int)
> (vg_replace_malloc.c:214) ==1995==    by 0x52F456B:
> Digikam::CollectionManager::updateLocations()
> (collectionmanager.cpp:1520)
> ==1995==    by 0x52F09D5: Digikam::CollectionManager::refresh()

Should be fixed in SVN. Missing delete only at destruction.

> 
> There is also a lots of report about databaseurl :
> 
> ==1995== 42 bytes in 1 blocks are definitely lost in loss record 4,659 of
> 7,413 ==1995==    at 0x4023D7C: malloc (vg_replace_malloc.c:195)
> ==1995==    by 0x6D7F63A: qMalloc(unsigned int) (in
> /usr/lib/libQtCore.so.4.6.2) ==1995==    by 0x5303F29:
> Digikam::DatabaseUrl::fromTagIds(QList<int> const&,
> Digikam::DatabaseParameters const&) (databaseurl.cpp:104)

DatabaseUrl is a KUrl, which is a QUrl, which is implicitly shared, so it's 
passed by value and we dont do any new/delete.
I suspect that the Urls are kept somewhere inside KIO when they are passed to 
the IOSlaves, but I dont know. It's difficult but not impossible to lose an 
implicitly shared object's data...

Marcel




More information about the Digikam-devel mailing list