return the amount of bytes written
authorfhanik <fhanik@13f79535-47bb-0310-9956-ffa450edef68>
Thu, 31 May 2007 11:51:34 +0000 (11:51 +0000)
committerfhanik <fhanik@13f79535-47bb-0310-9956-ffa450edef68>
Thu, 31 May 2007 11:51:34 +0000 (11:51 +0000)
git-svn-id: https://svn.apache.org/repos/asf/tomcat/trunk@543117 13f79535-47bb-0310-9956-ffa450edef68

java/org/apache/coyote/http11/InternalNioOutputBuffer.java

index a7cbf6d..9891ab1 100644 (file)
@@ -419,7 +419,7 @@ public class InternalNioOutputBuffer
 
     }
 
-    private synchronized void writeToSocket(ByteBuffer bytebuffer, boolean flip) throws IOException {
+    private synchronized int writeToSocket(ByteBuffer bytebuffer, boolean flip) throws IOException {
         //int limit = bytebuffer.position();
         if ( flip ) bytebuffer.flip();
         int written = 0;
@@ -440,6 +440,7 @@ public class InternalNioOutputBuffer
         }
         socket.getBufHandler().getWriteBuffer().clear();
         this.total = 0;
+        return written;
     }