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

Timothy Bish commented on AMQNET-404:
-------------------------------------

Patch with unit tests welcomed. 
                
> ActiveMQByteMessage Content accessing multiple times wipes the property
> -----------------------------------------------------------------------
>
>                 Key: AMQNET-404
>                 URL: https://issues.apache.org/jira/browse/AMQNET-404
>             Project: ActiveMQ .Net
>          Issue Type: Bug
>          Components: ActiveMQ
>    Affects Versions: 1.5.6
>            Reporter: Daniel Marbach
>            Assignee: Jim Gomes
>            Priority: Minor
>
> If you have an IBytesMessage and for example do the following:
> byte[] content = null;
> if (message.Content!= null)
> {
>    content  = message.Content;
> }
> Accessing content the first time will return the correct data.
> Accessing a second time the content property will return an empty byte array 
> which has the length of the data but all bytes are zero.
> It is OK that the content property is evaluated lazily but it should not 
> return different data when accessing multiple times. So accessing the 
> property the first time should read the buffer and assign it to a field and 
> then always return that byte buffer.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to