Re: Setting wantsLayer = YES; crashes on view load.
Re: Setting wantsLayer = YES; crashes on view load.
- Subject: Re: Setting wantsLayer = YES; crashes on view load.
- From: Kevin Ross <email@hidden>
- Date: Tue, 2 Jun 2009 01:36:34 -0700
Turns out I did have an spurious NSNotificationCenter registration in
a loaded view that was causing the crash. Thank you for your help
Michael!
On Jun 1, 2009, at 7:31 PM, Kevin Ross wrote:
I looked at the msgSends dump of everything after setWantsLayer, and
at the end it looks like a NSAutoreleasePool is being created right
before a CAContext is initialized. It then throws an exception
right after NSCFString NSCFString copyWithZone:.
+ NSAutoreleasePool NSObject alloc
+ NSAutoreleasePool NSAutoreleasePool allocWithZone:
+ NSAutoreleasePool NSObject self
- NSAutoreleasePool NSAutoreleasePool init
- NSAutoreleasePool NSAutoreleasePool initWithCapacity:
- NSAutoreleasePool NSObject class
+ NSAutoreleasePool NSObject self
+ CAContext NSObject initialize
+ CAContext CAContext localContext
+ CAContext CAContext localContextWithOptions:
+ CAContextImpl CAContextImpl initialize
+ CAContextImpl NSObject alloc
+ CAContextImpl NSObject allocWithZone:
- CAContextImpl CAContextImpl initWithOptions:
- CAContext NSObject init
+ NSConcreteNotification NSConcreteNotification
newTempNotificationWithName:object:userInfo:
- NSCFString NSCFString copyWithZone:
Is there a way using instruments or dtrace to find out what objects
are being passed to newTempNotificationWithName:object:userInfo?
Thank you for your time,
Kevin
On Jun 1, 2009, at 1:27 PM, Kevin Ross wrote:
Thanks Michael,
I do have a few notifications registered throughout the app, but
nothing that is connected with any of the CALayers or views. This
seems to happen no matter which view or nib I use. I'm trying to
see if I can isolate the notification that is causing the crash.
On Jun 1, 2009, at 12:07 AM, Michael Vannorsdel wrote:
Are you registering for any notifications? It looks like it's
crashing while trying to notify an object.
On Jun 1, 2009, at 12:31 AM, Kevin Ross wrote:
Hi everyone, I have a Core Data document based app that I've been
working on for a while and I now want to change some of the view
drawing to use CALayers. The trouble I'm having is that when I
set a view's wantsLayer = YES, I end up getting
EXC_BAD_ACCESS. This happens when I try to set it on any
arbitrary view in any of the nibs in my project, when setting it
from code, or from clicking the checkbox in IB. I've tried new
CALayer projects from scratch and they work fine, is there
something I could have done to my project that would prevent me
from setting a view's wantsLayer property to YES?
Thank you for taking time to read this.
_______________________________________________
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
_______________________________________________
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
_______________________________________________
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