This is an automated email from the ASF dual-hosted git repository.
markt pushed a commit to branch 11.0.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git
The following commit(s) were added to refs/heads/11.0.x by this push:
new e0057cb2b5 One more location where EVP_PKEY_free is required spotted
by CoPilot
e0057cb2b5 is described below
commit e0057cb2b58777de1933cc2bab65f458aefad85b
Author: Mark Thomas <[email protected]>
AuthorDate: Thu Apr 9 11:50:35 2026 +0100
One more location where EVP_PKEY_free is required spotted by CoPilot
---
java/org/apache/tomcat/util/net/openssl/panama/OpenSSLContext.java | 1 +
1 file changed, 1 insertion(+)
diff --git a/java/org/apache/tomcat/util/net/openssl/panama/OpenSSLContext.java
b/java/org/apache/tomcat/util/net/openssl/panama/OpenSSLContext.java
index 9ea93952ca..5f420a9a72 100644
--- a/java/org/apache/tomcat/util/net/openssl/panama/OpenSSLContext.java
+++ b/java/org/apache/tomcat/util/net/openssl/panama/OpenSSLContext.java
@@ -1249,6 +1249,7 @@ public class OpenSSLContext implements
org.apache.tomcat.util.net.SSLContext {
}
if (SSL_CTX_use_certificate(state.sslCtx, x509cert) <= 0) {
logLastError("openssl.errorLoadingCertificate");
+ EVP_PKEY_free(privateKeyAddress);
X509_free(x509cert);
return false;
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]