Skip to content

Commit 128e95d

Browse files
committed
buffer: update atob error code comments
Signed-off-by: haramjeong <04harams77@gmail.com>
1 parent 39e840e commit 128e95d

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/node_buffer.cc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1456,7 +1456,7 @@ static void Btoa(const FunctionCallbackInfo<Value>& args) {
14561456
// In case of error, a negative value is returned:
14571457
// * -1 indicates a single character remained,
14581458
// * -2 indicates an invalid character,
1459-
// * -3 indicates a possible overflow (i.e., more than 2 GB output).
1459+
// * -3 indicates an unrecognized simdutf error.
14601460
static void Atob(const FunctionCallbackInfo<Value>& args) {
14611461
CHECK_EQ(args.Length(), 1);
14621462
Environment* env = Environment::GetCurrent(args);
@@ -1501,7 +1501,7 @@ static void Atob(const FunctionCallbackInfo<Value>& args) {
15011501
return args.GetReturnValue().Set(value);
15021502
}
15031503

1504-
// Default value is: "possible overflow"
1504+
// Default value is: "unrecognized simdutf error"
15051505
int32_t error_code = -3;
15061506

15071507
if (result.error == simdutf::error_code::INVALID_BASE64_CHARACTER) {

0 commit comments

Comments
 (0)