Skip to content

Commit

Permalink
src: remove unnecessary cast in crypto_sig.cc
Browse files Browse the repository at this point in the history
ByteSource::Allocated accepts a void pointer now, so we do not need to
cast the argument to a char pointer.

Refs: nodejs#43202

PR-URL: nodejs#44001
Reviewed-By: Filip Skokan <panva.ip@gmail.com>
Reviewed-By: Darshan Sen <raisinten@gmail.com>
Reviewed-By: Feng Yu <F3n67u@outlook.com>
  • Loading branch information
tniessen authored and Fyko committed Sep 15, 2022
1 parent 067f5d3 commit 41264b0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/crypto/crypto_sig.cc
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ ByteSource ConvertSignatureToDER(

CHECK_NOT_NULL(data);

return ByteSource::Allocated(reinterpret_cast<char*>(data), len);
return ByteSource::Allocated(data, len);
}

void CheckThrow(Environment* env, SignBase::Error error) {
Expand Down

0 comments on commit 41264b0

Please sign in to comment.