[
https://issues.apache.org/jira/browse/PROTON-2869?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17926546#comment-17926546
]
ASF subversion and git services commented on PROTON-2869:
---------------------------------------------------------
Commit ca26da4b18913bf2825cacc097d0cb0c25bc77ec in qpid-protonj2's branch
refs/heads/main from Arnaud Cogoluègnes
[ https://gitbox.apache.org/repos/asf?p=qpid-protonj2.git;h=ca26da4b ]
PROTON-2869 Fix smalllong decoding
> Decoding of smalllong is broker for negative values
> ---------------------------------------------------
>
> Key: PROTON-2869
> URL: https://issues.apache.org/jira/browse/PROTON-2869
> Project: Qpid Proton
> Issue Type: Bug
> Components: protonj2
> Affects Versions: protonj2-1.0.0-M22
> Reporter: Arnaud Cogoluègnes
> Assignee: Timothy A. Bish
> Priority: Major
>
> The current code {{ANDs}} the byte value of the {{smalllong}} with {{0xFF}}.
> This is not necessary for a byte. Moreover {{0xFF}} is an {{int}} in Java, so
> the {{smalllong}} value is first converted to an {{int}} as well, making it
> positive (e.g. {{(byte) -1 & 0xFF = 255}}).
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]