You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by ma...@apache.org on 2015/02/22 19:49:14 UTC

svn commit: r1661513 - /tomcat/trunk/java/org/apache/coyote/http11/Http11Nio2Protocol.java

Author: markt
Date: Sun Feb 22 18:49:14 2015
New Revision: 1661513

URL: http://svn.apache.org/r1661513
Log:
Remove call to awaitBytes from longPoll for NIO2 as it could trigger
double registrations

Modified:
    tomcat/trunk/java/org/apache/coyote/http11/Http11Nio2Protocol.java

Modified: tomcat/trunk/java/org/apache/coyote/http11/Http11Nio2Protocol.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/coyote/http11/Http11Nio2Protocol.java?rev=1661513&r1=1661512&r2=1661513&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/coyote/http11/Http11Nio2Protocol.java (original)
+++ tomcat/trunk/java/org/apache/coyote/http11/Http11Nio2Protocol.java Sun Feb 22 18:49:14 2015
@@ -16,8 +16,6 @@
  */
 package org.apache.coyote.http11;
 
-import java.nio.channels.ReadPendingException;
-
 import org.apache.coyote.Processor;
 import org.apache.juli.logging.Log;
 import org.apache.juli.logging.LogFactory;
@@ -152,16 +150,6 @@ public class Http11Nio2Protocol extends
             if (processor.isAsync()) {
                 socket.setAsync(true);
                 ((Nio2Endpoint) getProtocol().getEndpoint()).addTimeout(socket);
-            } else if (processor.isUpgrade()) {
-                if (((Nio2SocketWrapper) socket).isUpgradeInit()) {
-                    try {
-                        ((Nio2SocketWrapper) socket).awaitBytes();
-                    } catch (ReadPendingException e) {
-                        // Ignore, the initial state after upgrade is
-                        // impossible to predict, and a read must be pending
-                        // to get a first notification
-                    }
-                }
             } else {
                 // Either:
                 //  - this is an upgraded connection



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