You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@pdfbox.apache.org by "Andreas Lehmkühler (JIRA)" <ji...@apache.org> on 2014/10/13 22:18:35 UTC
[jira] [Closed] (PDFBOX-1927) ClassCastException: COSInteger cannot
be cast to COSObject
[ https://issues.apache.org/jira/browse/PDFBOX-1927?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Andreas Lehmkühler closed PDFBOX-1927.
--------------------------------------
Resolution: Not a Problem
Assignee: Andreas Lehmkühler
Closed, as it works fine using the non sequential parser.
BTW, we can't deprecate the load method as the signing still depends on it.
> ClassCastException: COSInteger cannot be cast to COSObject
> ----------------------------------------------------------
>
> Key: PDFBOX-1927
> URL: https://issues.apache.org/jira/browse/PDFBOX-1927
> Project: PDFBox
> Issue Type: Bug
> Components: Parsing
> Affects Versions: 1.8.4
> Environment: Windows 7 64 bit
> Reporter: CP
> Assignee: Andreas Lehmkühler
> Priority: Critical
> Attachments: FlexRiskTrackerPrompt_166.pdf, TestPDFBox.java
>
>
> Calling PDDocument.load("myPDF.pdf") throws ClassCastException.
> I will attach a short sample program and PDF.
> {code}
> 2014-02-19 14:01:11,220 WARN [org.apache.pdfbox.pdfparser.BaseParser] (main) Invalid dictionary, found: '?' but expected: '/'
> Exception in thread "main" org.apache.pdfbox.exceptions.WrappedIOException
> at org.apache.pdfbox.pdfparser.PDFParser.parse(PDFParser.java:263)
> at org.apache.pdfbox.pdmodel.PDDocument.load(PDDocument.java:1238)
> at org.apache.pdfbox.pdmodel.PDDocument.load(PDDocument.java:1203)
> at org.apache.pdfbox.pdmodel.PDDocument.load(PDDocument.java:1128)
> at com.biosignia.framework.functionalTests.webServices.TestPDFBox.main(TestPDFBox.java:12)
> Caused by: java.lang.ClassCastException: org.apache.pdfbox.cos.COSInteger cannot be cast to org.apache.pdfbox.cos.COSObject
> at org.apache.pdfbox.pdfparser.PDFParser.readVersionInTrailer(PDFParser.java:859)
> at org.apache.pdfbox.pdfparser.PDFParser.parseTrailer(PDFParser.java:845)
> at org.apache.pdfbox.pdfparser.PDFParser.parseObject(PDFParser.java:502)
> at org.apache.pdfbox.pdfparser.PDFParser.parse(PDFParser.java:194)
> ... 4 more
> {code>
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)