From: fhanik Date: Fri, 13 Apr 2007 15:33:44 +0000 (+0000) Subject: if the flush is not guaranteed, then try again X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=60de69a42fa93dcdbc2ed1dbd5e4d628c2461868;p=tomcat7.0 if the flush is not guaranteed, then try again git-svn-id: https://svn.apache.org/repos/asf/tomcat/tc6.0.x/trunk@528526 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/java/org/apache/coyote/http11/InternalNioOutputBuffer.java b/java/org/apache/coyote/http11/InternalNioOutputBuffer.java index cf0c6bb88..c37fc61f0 100644 --- a/java/org/apache/coyote/http11/InternalNioOutputBuffer.java +++ b/java/org/apache/coyote/http11/InternalNioOutputBuffer.java @@ -604,7 +604,7 @@ public class InternalNioOutputBuffer int total = 0; private synchronized void addToBB(byte[] buf, int offset, int length) throws IOException { - if (socket.getBufHandler().getWriteBuffer().remaining() < length) { + while (socket.getBufHandler().getWriteBuffer().remaining() < length) { flushBuffer(); } socket.getBufHandler().getWriteBuffer().put(buf, offset, length);