Tilman Hausherr created PDFBOX-2543:
---------------------------------------

             Summary: ClassCastException in PDFontDescriptor.getFontFile2
                 Key: PDFBOX-2543
                 URL: https://issues.apache.org/jira/browse/PDFBOX-2543
             Project: PDFBox
          Issue Type: Bug
          Components: Parsing
    Affects Versions: 2.0.0
            Reporter: Tilman Hausherr
            Priority: Minor
             Fix For: 2.0.0


{code}
java.lang.ClassCastException: org.apache.pdfbox.cos.COSDictionary cannot be 
cast to org.apache.pdfbox.cos.COSStream
        at 
org.apache.pdfbox.pdmodel.font.PDFontDescriptor.getFontFile2(PDFontDescriptor.java:766)
{code}

The cause:
{code}
/FontFile2 880 0 R 
>> 
endobj
880 0 obj
<< 
/Type /Font 
/Name /Helv 
/BaseFont /Helvetica 
/Subtype /Type1 
/Encoding 881 0 R 
>> 
endobj
{code}
I will change all three getFontFile methods to check for the correct class 
instance instead of for null.




--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to