> On May 22, 2015, at 6:42 PM, Jens Alfke <j...@mooseyard.com> wrote:
> 
> I’m trying to debug a mysterious crash in a Swift init method. At the end of 
> the method there are some calls to objc_release generated by the compiler, 
> and it’s the first of these that crashes: the object being released has has 
> its ‘isa’ pointer replaced by the value 0xbaddc0dedeadbead. This is obviously 
> a magic value that someone put there to indicate the pointer isn’t valid, but 
> I’ve never seen that particular value before. I’m guessing that it’s 
> something to do with the Swift runtime.
> 
> I’ve turned on NSZombieEnabled but it doesn’t make a difference. And the 
> object address doesn’t correspond to any parameter of the init method, nor is 
> it the receiver (the class inherits from NSObject.) The crash is also not 
> consistent; sometimes it doesn’t happen. I’m drawing a blank. Does anyone 
> know what this means?
> 
> (Oh, and this is in a 64-bit Mac OS X process. It’s a small all-Swift app I 
> just started writing this week, which used to work until an hour ago, so I 
> don’t think there’s any mysterious memory corruption involved.)

free() does that sometimes. If zombies doesn't find anything then try guard 
malloc.


-- 
Greg Parker     gpar...@apple.com     Runtime Wrangler



_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to