Skip to content
New issue

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

Reading nested NoopStreams with sharebuf=false produces garbage data #186

Closed
nhz2 opened this issue Mar 22, 2024 · 0 comments · Fixed by #187
Closed

Reading nested NoopStreams with sharebuf=false produces garbage data #186

nhz2 opened this issue Mar 22, 2024 · 0 comments · Fixed by #187
Labels

Comments

@nhz2
Copy link
Member

nhz2 commented Mar 22, 2024

Here is an example:

using Test
using TranscodingStreams
stream = NoopStream(NoopStream(IOBuffer("foobar")); sharedbuf=false)
@test map(x->read(stream, UInt8), 1:6) == b"foobar"

Gives random bytes:

 Evaluated: UInt8[0x70, 0x2c, 0x93, 0x02, 0x00, 0x00] == UInt8[0x66, 0x6f, 0x6f, 0x62, 0x61, 0x72]

This bug was added in #168

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
1 participant