This is an automated email from the ASF dual-hosted git repository.

remm pushed a commit to branch 9.0.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/9.0.x by this push:
     new f735eb8  Remove useless private static method
f735eb8 is described below

commit f735eb896936ceca15a12a9b291259d0bb0d5246
Author: remm <r...@apache.org>
AuthorDate: Thu Feb 11 11:19:13 2021 +0100

    Remove useless private static method
---
 java/org/apache/tomcat/util/net/openssl/OpenSSLEngine.java | 13 ++++---------
 1 file changed, 4 insertions(+), 9 deletions(-)

diff --git a/java/org/apache/tomcat/util/net/openssl/OpenSSLEngine.java 
b/java/org/apache/tomcat/util/net/openssl/OpenSSLEngine.java
index cdd0617..27dbb80 100644
--- a/java/org/apache/tomcat/util/net/openssl/OpenSSLEngine.java
+++ b/java/org/apache/tomcat/util/net/openssl/OpenSSLEngine.java
@@ -251,7 +251,7 @@ public final class OpenSSLEngine extends SSLEngine 
implements SSLUtil.ProtocolIn
         } else {
             ByteBuffer buf = ByteBuffer.allocateDirect(len);
             try {
-                final long addr = memoryAddress(buf);
+                final long addr = Buffer.address(buf);
 
                 src.limit(pos + len);
 
@@ -291,7 +291,7 @@ public final class OpenSSLEngine extends SSLEngine 
implements SSLUtil.ProtocolIn
         } else {
             ByteBuffer buf = ByteBuffer.allocateDirect(len);
             try {
-                final long addr = memoryAddress(buf);
+                final long addr = Buffer.address(buf);
 
                 buf.put(src);
 
@@ -330,7 +330,7 @@ public final class OpenSSLEngine extends SSLEngine 
implements SSLUtil.ProtocolIn
             final int len = Math.min(MAX_ENCRYPTED_PACKET_LENGTH, limit - pos);
             final ByteBuffer buf = ByteBuffer.allocateDirect(len);
             try {
-                final long addr = memoryAddress(buf);
+                final long addr = Buffer.address(buf);
 
                 final int sslRead = SSL.readFromSSL(ssl, addr, len);
                 if (sslRead > 0) {
@@ -364,7 +364,7 @@ public final class OpenSSLEngine extends SSLEngine 
implements SSLUtil.ProtocolIn
         } else {
             final ByteBuffer buf = ByteBuffer.allocateDirect(pending);
             try {
-                final long addr = memoryAddress(buf);
+                final long addr = Buffer.address(buf);
 
                 final int bioRead = SSL.readFromBIO(networkBIO, addr, pending);
                 if (bioRead > 0) {
@@ -966,11 +966,6 @@ public final class OpenSSLEngine extends SSLEngine 
implements SSLUtil.ProtocolIn
         SSL.getLastErrorNumber();
     }
 
-
-    private static long memoryAddress(ByteBuffer buf) {
-        return Buffer.address(buf);
-    }
-
     private SSLEngineResult.Status getEngineStatus() {
         return engineClosed ? SSLEngineResult.Status.CLOSED : 
SSLEngineResult.Status.OK;
     }


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org

Reply via email to