Hi Marcus,

I've had a crash while dearchiving core text objects, though not this 
particular case with archiving.

Obviously the object that's crashing is a UIFont used by the 
NSAttributedString. One of its properties - by the look of it the font ascent - 
triggers the underlying C++ code to calculate the metrics of the font. It's 
possible that the font is corrupt and the code just isn't ready to handle the 
possibility. Can you try with a different font and see if the problem goes away?

It's probably worth filing a radar because I would say that archiving arbitrary 
fonts either needs to work robustly or fail cleanly. When I filed a radar on a 
similar kind of fault recently it got notified as a dupe, so some of these 
issues are known.

--Graham


On 20 Jan 2014, at 5:54 am, Markus Spoettl <ms_li...@shiftoption.com> wrote:

> I got a crash log from a user that's mildly puzzling. It happens somewhere 
> deep down CoreText it seems, while encoding an NSAttributedString (whose 
> content I don't know). Any ideas how it can some to this?

> []

> Thread 0 Crashed:
> 0   ???               0x7300786966657250 0 + 8286755708446536272
> 1   CoreText          0x000000018c689bd8 
> TBaseFont::CalculateFontMetrics(bool) const + 100
> 2   CoreText          0x000000018c699930 
> TComponentFont::CalculateFontMetrics(bool) const + 52
> 3   CoreText          0x000000018c689a2c TBaseFont::InitFontMetrics() const + 
> 64
> 4   CoreText          0x000000018c70bec8 TBaseFont::GetStrikeMetrics(double, 
> CGAffineTransform const*, bool) const + 96
> 5   CoreText          0x000000018c689774 TFont::InitStrikeMetrics() const + 64
> 6   CoreText          0x000000018c689704 CTFontGetAscent + 120
> 7   GraphicsServices  0x00000001917ffc14 GSFontEnsureExtraData + 256
> 8   GraphicsServices  0x0000000191802940 GSFontGetExtraData + 52
> 9   UIFoundation      0x0000000194c3ee00 -[UIFont isIBTextStyleFont] + 12
> 10  UIFoundation      0x0000000194c3e904 -[UIFont encodeWithCoder:] + 112


_______________________________________________

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