Skip to content

Commit

Permalink
crypto: add missing return value check
Browse files Browse the repository at this point in the history
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 <[email protected]>
PR-URL: #56615
Reviewed-By: Luigi Pinca <[email protected]>
Reviewed-By: James M Snell <[email protected]>
  • Loading branch information
mhdawson authored and aduh95 committed Jan 30, 2025
1 parent bcc1c65 commit d83d89a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/crypto/crypto_context.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1164,7 +1164,7 @@ void SecureContext::LoadPKCS12(const FunctionCallbackInfo<Value>& args) {
X509* ca = sk_X509_value(extra_certs.get(), i);

X509_STORE_add_cert(sc->GetCertStoreOwnedByThisSecureContext(), ca);
SSL_CTX_add_client_CA(sc->ctx_.get(), ca);
CHECK_EQ(1, SSL_CTX_add_client_CA(sc->ctx_.get(), ca));
}
ret = true;

Expand Down

0 comments on commit d83d89a

Please sign in to comment.