Uploaded image for project: 'Tika'
  1. Tika
  2. TIKA-2068

RTFParser crashes with NullPointerException

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Duplicate
    • 1.13
    • 1.14
    • parser
    • None

    Description

      The RTFParser seems to crash on RTF files containing pictures. The attached file produces the following stacktrace:

      java.lang.NullPointerException
      at org.apache.tika.mime.MimeTypesFactory.create(MimeTypesFactory.java:90)
      at org.apache.tika.mime.MimeTypesFactory.create(MimeTypesFactory.java:174)
      at org.apache.tika.mime.MimeTypes.getDefaultMimeTypes(MimeTypes.java:577)
      at org.apache.tika.config.TikaConfig.getDefaultMimeTypes(TikaConfig.java:69)
      at org.apache.tika.config.TikaConfig.<init>(TikaConfig.java:218)
      at org.apache.tika.config.TikaConfig.getDefaultConfig(TikaConfig.java:341)
      at org.apache.tika.parser.rtf.RTFEmbObjHandler.getConfig(RTFEmbObjHandler.java:263)
      at org.apache.tika.parser.rtf.RTFEmbObjHandler.getExtension(RTFEmbObjHandler.java:242)
      at org.apache.tika.parser.rtf.RTFEmbObjHandler.extractObj(RTFEmbObjHandler.java:219)
      at org.apache.tika.parser.rtf.RTFEmbObjHandler.handleCompletedObject(RTFEmbObjHandler.java:198)
      at org.apache.tika.parser.rtf.TextExtractor.processGroupEnd(TextExtractor.java:1357)
      at org.apache.tika.parser.rtf.TextExtractor.extract(TextExtractor.java:456)
      at org.apache.tika.parser.rtf.TextExtractor.extract(TextExtractor.java:439)
      at org.apache.tika.parser.rtf.RTFParser.parse(RTFParser.java:87)

      Attachments

        1. Styrodur C - 2800_C.rtf
          142 kB
          Nam-Quang Tran

        Issue Links

          Activity

            People

              Unassigned Unassigned
              qforce Nam-Quang Tran
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: