Skip to content

Commit 8346b8f

Browse files
mhdawsonaduh95
authored andcommittedFeb 3, 2025
crypto: add missing return value check
Add return value check for call to SSL_CTX_add_client_CA to be consistent with other places it is called Fixed unused warning in one of the static analysis tools we use at Red Hat even though it is not being reported by coverity in the configuration we run. Signed-off-by: Michael Dawson <midawson@redhat.com> PR-URL: #56615 Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
1 parent 9827f7d commit 8346b8f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed
 

Diff for: ‎src/crypto/crypto_context.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -1164,7 +1164,7 @@ void SecureContext::LoadPKCS12(const FunctionCallbackInfo<Value>& args) {
11641164
X509* ca = sk_X509_value(extra_certs.get(), i);
11651165

11661166
X509_STORE_add_cert(sc->GetCertStoreOwnedByThisSecureContext(), ca);
1167-
SSL_CTX_add_client_CA(sc->ctx_.get(), ca);
1167+
CHECK_EQ(1, SSL_CTX_add_client_CA(sc->ctx_.get(), ca));
11681168
}
11691169
ret = true;
11701170

0 commit comments

Comments
 (0)