diff options
author | Tobias Nießen <tniessen@tnie.de> | 2022-09-01 10:09:22 +0300 |
---|---|---|
committer | Filip Skokan <panva.ip@gmail.com> | 2022-09-01 15:46:43 +0300 |
commit | c8dc553430ce3fa8e4d3e2b4388d6abf23ab8269 (patch) | |
tree | e542d88dc6e5c4704015a2d8181d76e5c0f2387a /src | |
parent | 8524793ebfa1d24a0f3557af4fd3d0a8955f63b0 (diff) |
src: fix incorrect comments in crypto
PR-URL: https://github.com/nodejs/node/pull/44470
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Filip Skokan <panva.ip@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Diffstat (limited to 'src')
-rw-r--r-- | src/crypto/crypto_cipher.cc | 2 | ||||
-rw-r--r-- | src/crypto/crypto_keygen.h | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/src/crypto/crypto_cipher.cc b/src/crypto/crypto_cipher.cc index 397f248f2ca..a6ce4de49d9 100644 --- a/src/crypto/crypto_cipher.cc +++ b/src/crypto/crypto_cipher.cc @@ -493,7 +493,7 @@ void CipherBase::InitIv(const char* cipher_type, // Throw if an IV was passed which does not match the cipher's fixed IV length // static_cast<int> for the iv_buf.size() is safe because we've verified - // prior that the value is not larger than MAX_INT. + // prior that the value is not larger than INT_MAX. if (!is_authenticated_mode && has_iv && static_cast<int>(iv_buf.size()) != expected_iv_len) { diff --git a/src/crypto/crypto_keygen.h b/src/crypto/crypto_keygen.h index b0743efb38d..ed7d5c0601f 100644 --- a/src/crypto/crypto_keygen.h +++ b/src/crypto/crypto_keygen.h @@ -200,8 +200,8 @@ struct KeyPairGenTraits final { }; struct SecretKeyGenConfig final : public MemoryRetainer { - size_t length; // Expressed a a number of bits - char* out = nullptr; // Placeholder for the generated key bytes + size_t length; // In bytes. + char* out = nullptr; // Placeholder for the generated key bytes. void MemoryInfo(MemoryTracker* tracker) const override; SET_MEMORY_INFO_NAME(SecretKeyGenConfig) |