We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The below test shows an issue where a duplicated ByteBuffer with a position > 0 is returning unexpected results:
ByteBuffer
position > 0
public void testDuplicatedByteBufferWithCustomPosition() throws IOException { final byte[] INPUT_BYTES = new byte[] { 1, 2, 3, 4, 5 }; String exp = MAPPER.writeValueAsString(new byte[] { 3, 4, 5 }); ByteBuffer bbuf = ByteBuffer.wrap(INPUT_BYTES); bbuf.position(2); ByteBuffer duplicated = bbuf.duplicate(); assertEquals(exp, MAPPER.writeValueAsString(duplicated)); }
Expected :"AwQF" Actual :"AQIDBAU="
I tested this on commit 6e5e2b0 with the 2.10 branch.
2.10
The text was updated successfully, but these errors were encountered:
Fix FasterXML#2602: Make sure ByteBufferSerializer takes position int…
c316aa1
…o account
I also added a potential fix in #2603
Sorry, something went wrong.
Thank you for reporting this, PR -- I hope to review this ASAP.
Update release notes wrt, made small changes to fix for #2602
edf82d1
c6da520
No branches or pull requests
The below test shows an issue where a duplicated
ByteBuffer
with aposition > 0
is returning unexpected results:I tested this on commit 6e5e2b0 with the
2.10
branch.The text was updated successfully, but these errors were encountered: