Commit 39e03b4673b for nodejs
commit 39e03b4673b8d53c107536a39eecf4ec8f648584
Author: Antoine du Hamel <duhamelantoine1995@gmail.com>
Date: Wed Oct 21 15:19:27 2026 +0200
crypto: use `OPENSSL_SIZE_T` instead of hard coding `int`
Signed-off-by: Antoine du Hamel <duhamelantoine1995@gmail.com>
PR-URL: https://github.com/nodejs/node/pull/66889
Reviewed-By: Filip Skokan <panva.ip@gmail.com>
Reviewed-By: Tim Perry <pimterry@gmail.com>
Reviewed-By: Ulises Gascón <ulisesgascongonzalez@gmail.com>
diff --git a/src/crypto/crypto_context.cc b/src/crypto/crypto_context.cc
index 05e8e5f85c0..13edcb58886 100644
--- a/src/crypto/crypto_context.cc
+++ b/src/crypto/crypto_context.cc
@@ -1494,7 +1494,7 @@ SpkiCheck CheckSPKIs(const STACK_OF(X509) * certs,
X509** offender,
int* depth) {
if (certs == nullptr) return SpkiCheck::kAllowed;
- for (int i = 0; i < sk_X509_num(certs); i++) {
+ for (OPENSSL_SIZE_T i = 0; i < sk_X509_num(certs); i++) {
X509* cert = sk_X509_value(certs, i);
SpkiCheck result = CheckSPKI(cert);
if (result != SpkiCheck::kAllowed) {