Re: GC bug in NSFontManager?
Re: GC bug in NSFontManager?
- Subject: Re: GC bug in NSFontManager?
- From: Tommy Nordgren <email@hidden>
- Date: Wed, 1 Jul 2009 03:45:30 +0200
On Jul 1, 2009, at 1:57 AM, Tommy Nordgren wrote:
On Jun 30, 2009, at 11:48 PM, Ross Carter wrote:
On Jun 30, 2009, at 3:33 PM, Quincey Morris wrote:
On Jun 30, 2009, at 11:34, Ross Carter wrote:
I am receiving crash reports for code that enumerates an array
returned by NSFontManager. The app is garbage-collected.
Chances are someone will recognize the exact problem and jump in
with an explanation, but in case not:
(a) Can you post back-traces from the points of failure
corresponding to the source code?
This one is typical:
Exception Type: EXC_BAD_ACCESS (SIGBUS) Exception Codes:
KERN_PROTECTION_FAILURE at 0x0000000000000063 Crashed Thread: 0
Application Specific Information: objc[1622]: garbage collection is
ON
Thread 0 Crashed:
0 libobjc.A.dylib 0x917e768c objc_msgSend + 28
1 com.apple.AppKit 0x94d3ef43 -[NSFontManager
availableMembersOfFontFamily:] + 963
2 com.cocomot.Pagehand 0x0003a706 -[CCMFontCollectionsController
fontNamesFamiliesDictionary] + 312
3 com.cocomot.Pagehand 0x0003a1fc -[CCMFontCollectionsController
fontCollectionsArrayForControls] + 60
4 com.cocomot.Pagehand 0x000305fe -[CCMApp init] + 806
5 com.apple.AppKit 0x94b48e03 -[NSCustomObject nibInstantiate] + 315
6 com.apple.AppKit 0x94b297f5 -[NSIBObjectData instantiateObject:]
+ 259
7 com.apple.AppKit 0x94b28f16 -[NSIBObjectData
nibInstantiateWithOwner:topLevelObjects:] + 297
8 com.apple.AppKit 0x94b1f616 loadNib + 264
9 com.apple.AppKit 0x94b1ef78 +[NSBundle(NSNibLoading)
_loadNibFile:nameTable:withZone:ownerBundle:] + 946
10 com.apple.AppKit 0x94b1ebbb +[NSBundle(NSNibLoading)
loadNibFile:externalNameTable:withZone:] + 171
11 com.apple.AppKit 0x94b1eaf9 +[NSBundle(NSNibLoading)
loadNibNamed:owner:] + 391
12 com.apple.AppKit 0x94b1e7a8 NSApplicationMain + 434
13 com.cocomot.Pagehand 0x00002d66 start + 54
Is CCMApp an NSApplication subclass. This stack trace seems to
indicate that there is an instance of it in
your nib/xib file.
If so, your application is initialized in an incorrect way, and
outlets in it may not be set up correctly.
To fix, delete it from your nib, and set the value for the key
NSPrincipalClass in your Info.plist file to CCMApp
(NSApplicationMain uses this key to create an instance of the
correct NSApplication (sub)class.
One more thing - you need to move the code from CCMApp init to
finishLaunching, a method that is invoked
immediately before the runloop starts
(b) Can you reproduce the problem locally? (That is, are you in a
position to try changes and see if the problem goes away?)
No, I have never seen it happen.
_______________________________________________
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
-------------------------------------------
Engineers supporting greenpeace: Comparable to Afroamericans who
wants to join the Ku Klux Klan
----------------------------------------
Tommy Nordgren
email@hidden
_______________________________________________
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
-------------------------------------
This sig is dedicated to the advancement of Nuclear Power
Tommy Nordgren
email@hidden
_______________________________________________
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