Uploaded image for project: 'PDFBox'
  1. PDFBox
  2. PDFBOX-2868

NPE in Acroform getValueAsString

VotersWatch issueWatchersLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 2.0.0
    • 2.0.0
    • AcroForm
    • None

    Description

      The most common exception in the first run of 2.0.0-trunk against govdocs1 is this:

      java.lang.NullPointerException
      	at org.apache.pdfbox.pdmodel.interactive.form.PDNonTerminalField.getValueAsString(PDNonTerminalField.java:181)
      	at org.apache.tika.parser.pdf.PDF2XHTML.addFieldString(PDF2XHTML.java:615)
      	at org.apache.tika.parser.pdf.PDF2XHTML.processAcroField(PDF2XHTML.java:580)
      	at org.apache.tika.parser.pdf.PDF2XHTML.extractAcroForm(PDF2XHTML.java:567)
      	at org.apache.tika.parser.pdf.PDF2XHTML.endDocument(PDF2XHTML.java:201)
      	at org.apache.pdfbox.text.PDFTextStripper.writeText(PDFTextStripper.java:250)
      	at org.apache.tika.parser.pdf.PDF2XHTML.process(PDF2XHTML.java:137)
      	at org.apache.tika.parser.pdf.PDFParser.parse(PDFParser.java:132)
      

      Attachments

        1. 543014.pdf
          32 kB
          Tim Allison

        Issue Links

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            msahyoun Maruan Sahyoun
            tallison Tim Allison
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment