You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@qpid.apache.org by "Rob Godfrey (JIRA)" <ji...@apache.org> on 2014/02/20 17:01:26 UTC

[jira] [Updated] (QPID-5569) NullPointerException if message prop's userId is null

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

Rob Godfrey updated QPID-5569:
------------------------------

    Fix Version/s: 0.27

> NullPointerException if message prop's userId is null
> -----------------------------------------------------
>
>                 Key: QPID-5569
>                 URL: https://issues.apache.org/jira/browse/QPID-5569
>             Project: Qpid
>          Issue Type: Bug
>          Components: Java Client
>    Affects Versions: 0.18
>            Reporter: Nathan Jensen
>            Assignee: Rob Godfrey
>             Fix For: 0.27
>
>
> Some JMS applications will try to retrieve the userID from a message, and the qpid client may throw a NullPointerException if that is not set on the message. Ideally it should just return null if there is no userId set. Specifically in org.apache.qpid.client.message.AMQMessageDelegate_0_10.java, the method getStringProperty(String) checks if the propertyName equals JMSXUserID and if so returns a new String(_messageProps.getUserId()). Therefore if there is no userId set it can attempt String(null) which causes a NullPointerException.
> Also note that other properties in this method are specifically checking for null to avoid an exception like this.



--
This message was sent by Atlassian JIRA
(v6.1.5#6160)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@qpid.apache.org
For additional commands, e-mail: dev-help@qpid.apache.org