[
https://issues.apache.org/jira/browse/PDFBOX-3093?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Tilman Hausherr resolved PDFBOX-3093.
-------------------------------------
Resolution: Fixed
Assignee: Tilman Hausherr
Fix Version/s: 2.0.0
Thanks!
> Exception in TTFParser
> ----------------------
>
> Key: PDFBOX-3093
> URL: https://issues.apache.org/jira/browse/PDFBOX-3093
> Project: PDFBox
> Issue Type: Bug
> Components: FontBox
> Affects Versions: 2.0.0
> Reporter: Timur Kamalov
> Assignee: Tilman Hausherr
> Fix For: 2.0.0
>
> Attachments: PT-286.pdf,
> Skipping_font_tables_with_zero_length_.patch, resfont.ttf
>
>
> The reason for this is an ambiguity in the TrueType specification. Namely,
> one of the font tables (OS/2) is present in the font directory with length 0.
> The specification itself is completely silent about this.
> The only other information I was able to find is:
> - the FreeType font library
> (http://www.freetype.org/freetype2/docs/reference/ft2-truetype_tables.html#FT_Sfnt_Table_Info)
> assumes that any table having 0 length in the font directory is treated as
> missing.
> - Google OpenType Sanitizer would report an error in such situation:
> https://github.com/khaledhosny/ots/blob/master/src/ots.cc, lines 575-578
> - there are several related discussions at Adobe forums:
> https://forums.adobe.com/thread/1616317 ,
> https://forums.adobe.com/thread/1611899
> As allowing zero length tables in TrueType fonts seems to be quite logical
> (and also implicitly confirmed by Adobe Acrobat validator), I've changed the
> TTFParser to skip tables with 0 length.
> Attaching patch and font file. Will add test file also if necessary.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]