tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ma...@apache.org
Subject svn commit: r1360616 - /tomcat/trunk/java/org/apache/coyote/http11/InternalNioOutputBuffer.java
Date Thu, 12 Jul 2012 10:19:57 GMT
Author: markt
Date: Thu Jul 12 10:19:57 2012
New Revision: 1360616

URL: http://svn.apache.org/viewvc?rev=1360616&view=rev
Log:
Remove unused code

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

Modified: tomcat/trunk/java/org/apache/coyote/http11/InternalNioOutputBuffer.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/coyote/http11/InternalNioOutputBuffer.java?rev=1360616&r1=1360615&r2=1360616&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/coyote/http11/InternalNioOutputBuffer.java (original)
+++ tomcat/trunk/java/org/apache/coyote/http11/InternalNioOutputBuffer.java Thu Jul 12 10:19:57
2012
@@ -334,7 +334,6 @@ public class InternalNioOutputBuffer ext
      */
     protected boolean flushBuffer(boolean block) throws IOException {
 
-        int result = 0;
         //prevent timeout for async,
         SelectionKey key = socket.getIOChannel().keyFor(socket.getPoller().getSelector());
         if (key != null) {
@@ -345,8 +344,8 @@ public class InternalNioOutputBuffer ext
         boolean dataLeft = hasMoreDataToFlush();
 
         //write to the socket, if there is anything to write
-        if ( dataLeft ) {
-            result = writeToSocket(socket.getBufHandler().getWriteBuffer(),block, !flipped);
+        if (dataLeft) {
+            writeToSocket(socket.getBufHandler().getWriteBuffer(),block, !flipped);
         }
 
         dataLeft = hasMoreDataToFlush();
@@ -360,10 +359,9 @@ public class InternalNioOutputBuffer ext
                     transfer(buffer.getBuf(), socket.getBufHandler().getWriteBuffer());
                     if (buffer.getBuf().remaining() == 0) {
                         bufIter.remove();
-    }
-                    result = writeToSocket(socket.getBufHandler().getWriteBuffer(),block,
true);
+                    }
+                    writeToSocket(socket.getBufHandler().getWriteBuffer(),block, true);
                     //here we must break if we didn't finish the write
-
                 }
             }
         }



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


Mime
View raw message