You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by fh...@apache.org on 2007/03/16 23:38:21 UTC

svn commit: r519168 - /tomcat/tc6.0.x/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java

Author: fhanik
Date: Fri Mar 16 15:38:19 2007
New Revision: 519168

URL: http://svn.apache.org/viewvc?view=rev&rev=519168
Log:
fixed minor bug introduced recently

Modified:
    tomcat/tc6.0.x/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java

Modified: tomcat/tc6.0.x/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java
URL: http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java?view=diff&rev=519168&r1=519167&r2=519168
==============================================================================
--- tomcat/tc6.0.x/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java (original)
+++ tomcat/tc6.0.x/trunk/java/org/apache/tomcat/util/net/NioEndpoint.java Fri Mar 16 15:38:19 2007
@@ -1145,11 +1145,11 @@
                 }
             } else {
                 final SelectionKey key = socket.getIOChannel().keyFor(socket.getPoller().getSelector());
-                final KeyAttachment att = (KeyAttachment) key.attachment();
-                //we are registering the key to start with, reset the fairness counter.
-                att.setFairness(0);
                 try {
                     if (key != null) {
+                        final KeyAttachment att = (KeyAttachment) key.attachment();
+                        //we are registering the key to start with, reset the fairness counter.
+                        att.setFairness(0);
                         key.interestOps(interestOps);
                         att.interestOps(interestOps);
                     }



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