[ 
https://issues.apache.org/jira/browse/PDFBOX-960?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Andreas Lehmkühler resolved PDFBOX-960.
---------------------------------------

    Resolution: Fixed
      Assignee: Andreas Lehmkühler

I adapted Kevins proposal as it is always a good idea to compare constants to 
given values and not vice versa.
I added those changes in revision 1070099.

Thanks for the contribution!

> Null Pointer Exception when Annotation is missing the Subtype
> -------------------------------------------------------------
>
>                 Key: PDFBOX-960
>                 URL: https://issues.apache.org/jira/browse/PDFBOX-960
>             Project: PDFBox
>          Issue Type: Bug
>          Components: PDModel
>    Affects Versions: 1.4.0
>            Reporter: Kevin Jackson
>            Assignee: Andreas Lehmkühler
>             Fix For: 1.5.0
>
>         Attachments: PDAnnotation.java.patch
>
>
> If an annotation is missing the required Subtype then calling 
> createAnnotation() will result in a NPE.
> A better result is to return null and let the upper level code handle it.

-- 
This message is automatically generated by JIRA.
-
For more information on JIRA, see: http://www.atlassian.com/software/jira


Reply via email to