Leonid Gorshenev created TIKA-4811:
--------------------------------------

             Summary: NullPointerException when OCR parser getSupportedTypes 
returns null
                 Key: TIKA-4811
                 URL: https://issues.apache.org/jira/browse/TIKA-4811
             Project: Tika
          Issue Type: Bug
            Reporter: Leonid Gorshenev


In {{{}doOCROnCurrentPage{}}}, {{ocrParser.getSupportedTypes(context)}} is 
called directly before invoking {{{}.contains(ocrImageMediaType){}}}. If 
third-party implementation of {{Parser}} returns null from 
{{{}getSupportedTypes(ParseContext){}}}, such call results in an unhandled 
NullPointerException rather than gracefully handling the missing media types or 
throwing a meaningful Exception.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to