Triggering an NSTextStorage Bug
Triggering an NSTextStorage Bug
- Subject: Triggering an NSTextStorage Bug
- From: Seth Willits <email@hidden>
- Date: Tue, 19 Mar 2013 16:54:59 -0700
This has taken me a *very long time* to narrow down to its simplest bits and it's very puzzling to me.
The short story is I have an NSTextStorage subclass as I'm doing many different things, syntax coloring among them. I would swear that everything I'm doing is a legitimate implementation, but there is obviously something causing internal behavior in the text system to go haywire. The result is that the text system itself (not me!) is over-releasing the NSParagraphStyle. The memory management in my code is solid, so the problem has to be in the text system itself.
The example project:
http://www.sethwillits.com/temp/PGSOverRelease.zip
There are a number of factors involved in reliably reproducing this behavior and this project has one set of circumstances that will reproduce it, but there are others. If you slightly change any of these factors (all changes which should have no effect), then the over-release crash does not occur.
I have read and re-read all of the text storage documentation multiple times and I am thusly confident that either some critical elusive behavior is undocumented or I've found a legitimate bug in the text system.
Any help would be greatly appreciated. This is severely impacting my work at the moment.
--
Seth Willits
_______________________________________________
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