Closed
Description
Version
21.6.0
Platform
Linux benchmark-S2600WFT 5.15.0-41-generic #44-Ubuntu x86_64 GNU/Linux
Subsystem
No response
What steps will reproduce the bug?
const { StringDecoder } = require('node:string_decoder');
const buf = Buffer.allocUnsafeSlow(2 ** 31);
console.log(decoder.write(buf).length); // 0
How often does it reproduce? Is there a required condition?
Always
What is the expected behavior? Why is that the expected behavior?
When executing console.log(decoder.write(buf).length);
, expect throw an string longer error instead of output 0
What do you see instead?
output: 0
Additional information
No response