Re: Problem assigning image to button under garbage collection
Re: Problem assigning image to button under garbage collection
- Subject: Re: Problem assigning image to button under garbage collection
- From: Rob Keniger <email@hidden>
- Date: Fri, 23 Jan 2009 16:12:15 +1000
On 23/01/2009, at 1:53 PM, Bill Bumgarner wrote:
A problem arose when I added an NSButton to my nib file and
assigned an image to it in Interface Builder (just entering the
image name NSAddTemplate) in the Inspector. As soon as I did this,
I started getting the following kinds of messages in the log:
MyApp (20733,0x100537000) malloc: free_garbage: garbage ptr =
0x8000be360, has non-zero refcount = 1
I tried different approaches to setting the image, such as doing it
programatically (keeping a persistent pointer to the image and
referring to the button via an IBOutlet).
I have googled about such problems, but did not come up with
anything. Is there a known issue with images and buttons under GC?
Sounds odd. Please file a bug, attaching the application (binary
is good enough unless you are comfortable attaching the source).
http://bugreporter.apple.com/
This has come up before and has been acknowledged as a bug in the
Frameworks. It's apparently harmless (but yes, it's very annoying).
http://www.cocoabuilder.com/archive/message/xcode/2007/11/7/16932
I know you've seen it before:
http://www.cocoabuilder.com/archive/message/cocoa/2007/12/23/195406
To see it all you have to do is launch Xcode (a GC app) and watch the
massive number of these log entries that it spews out.
It occurs as soon as a template image is loaded.
You can recreate this at will with a blank Xcode project set to use
Garbage Collection. Just add an NSButton to the main window and set
its image to be NSAddTemplate or another template image and run the app.
--
Rob Keniger
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden