[ 
https://issues.apache.org/jira/browse/ARIES-847?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13269721#comment-13269721
 ] 

Sergey Beryozkin commented on ARIES-847:
----------------------------------------

Check for 'null' is redundant. Instanceof will always return false if a left 
operand is null. I don't have a reference to the relevant JVM section to prove 
it :-), but it is true. Similarly, the string concatenation would convert a 
null object to 'null.
                
> Nullpointer exception in 
> org.apache.aries.blueprint.container.BeanRecipe.destroy
> --------------------------------------------------------------------------------
>
>                 Key: ARIES-847
>                 URL: https://issues.apache.org/jira/browse/ARIES-847
>             Project: Aries
>          Issue Type: Bug
>          Components: Blueprint
>    Affects Versions: 0.4
>            Reporter: Christian Schneider
>            Assignee: Sergey Beryozkin
>             Fix For: 0.4
>
>         Attachments: aries-847-1.patch
>
>
> If the blueprint file contains an error the obj given to destroy may be null. 
> Currently this is not handled. The big problem in this case is that the user 
> does not get a good error message about his error in the context.
> I will add a patch with the check.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to