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

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


The following commit(s) were added to refs/heads/8.5.x by this push:
     new 72fc186048 Align with 9.0.x, 10.1.x & 11.0.x
72fc186048 is described below

commit 72fc18604887c6946ec5b93942ed8348761fb207
Author: Mark Thomas <ma...@apache.org>
AuthorDate: Thu Apr 6 16:40:02 2023 +0100

    Align with 9.0.x, 10.1.x & 11.0.x
---
 java/org/apache/tomcat/websocket/WsRemoteEndpointImplBase.java | 2 +-
 java/org/apache/tomcat/websocket/WsWebSocketContainer.java     | 5 +++--
 2 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/java/org/apache/tomcat/websocket/WsRemoteEndpointImplBase.java 
b/java/org/apache/tomcat/websocket/WsRemoteEndpointImplBase.java
index 16068e6dae..e605105013 100644
--- a/java/org/apache/tomcat/websocket/WsRemoteEndpointImplBase.java
+++ b/java/org/apache/tomcat/websocket/WsRemoteEndpointImplBase.java
@@ -408,7 +408,7 @@ public abstract class WsRemoteEndpointImplBase implements 
RemoteEndpoint {
     }
 
 
-    protected void endMessage(SendHandler handler, SendResult result) {
+    void endMessage(SendHandler handler, SendResult result) {
         boolean doWrite = false;
         MessagePart mpNext = null;
         synchronized (messagePartLock) {
diff --git a/java/org/apache/tomcat/websocket/WsWebSocketContainer.java 
b/java/org/apache/tomcat/websocket/WsWebSocketContainer.java
index 26515af74e..75cd966e45 100644
--- a/java/org/apache/tomcat/websocket/WsWebSocketContainer.java
+++ b/java/org/apache/tomcat/websocket/WsWebSocketContainer.java
@@ -306,7 +306,7 @@ public class WsWebSocketContainer implements 
WebSocketContainer, BackgroundProce
                 // Regardless of whether a non-secure wrapper was created for a
                 // proxy CONNECT, need to use TLS from this point on so wrap 
the
                 // original AsynchronousSocketChannel
-                SSLEngine sslEngine = createSSLEngine(userProperties, host, 
port);
+                SSLEngine sslEngine = 
createSSLEngine(clientEndpointConfiguration, host, port);
                 channel = new AsyncChannelWrapperSecure(socketChannel, 
sslEngine);
             } else if (channel == null) {
                 // Only need to wrap as this point if it wasn't wrapped to 
process a
@@ -885,9 +885,10 @@ public class WsWebSocketContainer implements 
WebSocketContainer, BackgroundProce
     }
 
 
-    private SSLEngine createSSLEngine(Map<String, Object> userProperties, 
String host, int port)
+    private SSLEngine createSSLEngine(ClientEndpointConfig 
clientEndpointConfig, String host, int port)
             throws DeploymentException {
 
+        Map<String, Object> userProperties = 
clientEndpointConfig.getUserProperties();
         try {
             // See if a custom SSLContext has been provided
             SSLContext sslContext = (SSLContext) 
userProperties.get(Constants.SSL_CONTEXT_PROPERTY);


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

Reply via email to