Jason Mackin created PDFBOX-3012:
------------------------------------

             Summary: PDAcroForm flatten() throws ClassCastException
                 Key: PDFBOX-3012
                 URL: https://issues.apache.org/jira/browse/PDFBOX-3012
             Project: PDFBox
          Issue Type: Bug
          Components: AcroForm
    Affects Versions: 2.0.0
            Reporter: Jason Mackin


In the PDAcroForm class, in the flatten() method,  there is a for loop that 
tries casting field to a PDTerminalField.  the field is sometimes a 
PDNonTerminalField and the casting error is thrown.

To fix this I just add one if statement right before the for loop that checks 
to see if field is an instance of PDTerminalField and place the for loop inside 
the if statement:

    if(field instanceof PDTerminalField){



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

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org

Reply via email to