-
-
Notifications
You must be signed in to change notification settings - Fork 35.3k
Buffer.from() output breaks after optimizing in nodejs 22.7 #54521
Copy link
Copy link
Closed
Labels
bufferIssues and PRs related to the buffer subsystem.Issues and PRs related to the buffer subsystem.confirmed-bugIssues with confirmed bugs.Issues with confirmed bugs.regressionIssues related to regressions.Issues related to regressions.v22.xIssues that can be reproduced on v22.x or PRs targeting the v22.x-staging branch.Issues that can be reproduced on v22.x or PRs targeting the v22.x-staging branch.
Metadata
Metadata
Assignees
Labels
bufferIssues and PRs related to the buffer subsystem.Issues and PRs related to the buffer subsystem.confirmed-bugIssues with confirmed bugs.Issues with confirmed bugs.regressionIssues related to regressions.Issues related to regressions.v22.xIssues that can be reproduced on v22.x or PRs targeting the v22.x-staging branch.Issues that can be reproduced on v22.x or PRs targeting the v22.x-staging branch.
Version
v22.7.0
Platform
Subsystem
Buffer
What steps will reproduce the bug?
How often does it reproduce? Is there a required condition?
For me, it will consistently fail somewhere between 7000 to 1200 iterations.
What is the expected behavior? Why is that the expected behavior?
In node 20 this code does not fail , even after 1_000_000 iterations.
Buffer.from("\x80").toString("hex")always returnsc280on node 20What do you see instead?
Buffer.from("\x80").toString("hex")incorrectly returns80after sufficient iterationsAdditional information
No response