PDA

View Full Version : cocoa bug ? - memory leak in apple example




Barbus
Oct 31, 2009, 05:10 AM
hi all

please try:
1 create new application using multi-document template
2 do nothing, just run this new application using leak-checking instrument
3 select save-as option - save panel appears ; expand it to show file icons
4 do nothing, just wait

result : you'll see memory leak

also you'll see memory leak in apple's native example ImageApp

the question: should I ignore such leaks in multi-document application or I did something wrong?

thanks



xStep
Oct 31, 2009, 02:58 PM
If no one replies back saying you did something wrong, then please file this with Apple as a bug.

jared_kipe
Nov 1, 2009, 11:38 AM
Every time I launch my application, and sometimes randomly while navigating through my UITabBar I get leaks from CoreGraphics for open_handle_to_dylib_path. Since I'm not doing anything directly with CoreGraphics, and I'm not leaking any UIobjects (that would use coregraphics) I assume its apple's mistake.

I move on and hope Apple will fix it in the future. But in this case I'm only loosing 128Bytes at a time and it doesn't happen very often.

Barbus
Nov 1, 2009, 01:40 PM
the caller of the leak I wrote about is :
-[NSNavFBENode _calculatePreviewThumbnailImageWithMaxSize:isThumbnail:]

imho it seems like CoreGraphics problem ...