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

NPE in sanitizeType in org.apache.pdfbox.pdmodel.PDPageTree

    Details

      Description

      Hello PDFBox developers,

      the attached file produces the follow NPE opening the pdf file:

      [20.11.2017 12:54:41.183] [Thread ID: 74] SEVERE: [vlh.notes.BSTArchive.File.filedialog.ImageConversionWorker]: doInBackground() java.lang.NullPointerException
      org.apache.pdfbox.pdmodel.PDPageTree sanitizeType: 219
      [20.11.2017 12:54:41.183] [Thread ID: 74] [vlh.notes.BSTArchive.File.filedialog.ImageConversionWorker]: org.apache.pdfbox.pdmodel.PDPageTree get: 211
      [20.11.2017 12:54:41.183] [Thread ID: 74] [vlh.notes.BSTArchive.File.filedialog.ImageConversionWorker]: org.apache.pdfbox.pdmodel.PDDocument getPage: 1391
      [20.11.2017 12:54:41.183] [Thread ID: 74] [vlh.notes.BSTArchive.File.filedialog.ImageConversionWorker]: org.apache.pdfbox.rendering.PDFRenderer renderImage: 108
      [20.11.2017 12:54:41.183] [Thread ID: 74] [vlh.notes.BSTArchive.File.filedialog.ImageConversionWorker]: org.apache.pdfbox.rendering.PDFRenderer renderImageWithDPI: 94
      [20.11.2017 12:54:41.183] [Thread ID: 74] [vlh.notes.BSTArchive.File.filedialog.ImageConversionWorker]: vlh.Tools.PDF.PDFBoxUtil generateImage: 789
      [20.11.2017 12:54:41.183] [Thread ID: 74] [vlh.notes.BSTArchive.File.filedialog.ImageConversionWorker]: vlh.notes.BSTArchive.File.pdf.PdfFileExtend generatePreviewImage: 164
      [20.11.2017 12:54:41.183] [Thread ID: 74] [vlh.notes.BSTArchive.File.filedialog.ImageConversionWorker]: vlh.notes.BSTArchive.File.filedialog.ImageConversionWorker doInBackground: 175
      [20.11.2017 12:54:41.183] [Thread ID: 74] [vlh.notes.BSTArchive.File.filedialog.ImageConversionWorker]: vlh.notes.BSTArchive.File.filedialog.ImageConversionWorker doInBackground: 1
      [20.11.2017 12:54:41.183] [Thread ID: 74] [vlh.notes.BSTArchive.File.filedialog.ImageConversionWorker]: javax.swing.SwingWorker$1 call: 288
      [20.11.2017 12:54:41.183] [Thread ID: 74] [vlh.notes.BSTArchive.File.filedialog.ImageConversionWorker]: java.util.concurrent.FutureTask$Sync innerRun: 314
      [20.11.2017 12:54:41.183] [Thread ID: 74] [vlh.notes.BSTArchive.File.filedialog.ImageConversionWorker]: java.util.concurrent.FutureTask run: 149
      [20.11.2017 12:54:41.183] [Thread ID: 74] [vlh.notes.BSTArchive.File.filedialog.ImageConversionWorker]: javax.swing.SwingWorker run: 327
      [20.11.2017 12:54:41.183] [Thread ID: 74] [vlh.notes.BSTArchive.File.filedialog.ImageConversionWorker]: java.util.concurrent.ThreadPoolExecutor$Worker runTask: 939
      [20.11.2017 12:54:41.183] [Thread ID: 74] [vlh.notes.BSTArchive.File.filedialog.ImageConversionWorker]: java.util.concurrent.ThreadPoolExecutor$Worker run: 963
      [20.11.2017 12:54:41.183] [Thread ID: 74] [vlh.notes.BSTArchive.File.filedialog.ImageConversionWorker]: java.lang.Thread run: 767

      The error started occuring with pdfbox release 2.0.8!
      The PDF has been generated by an older samsung scan software. Adobe Reader and Foxit are able to open the file correctly.

        Attachments

        1. VLH.pdf
          55 kB
          Nico Prenzel

          Issue Links

            Activity

              People

              • Assignee:
                lehmi Andreas Lehmkühler
                Reporter:
                NicoPrenzel Nico Prenzel
              • Votes:
                0 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: