protect write loop
git-svn-id: svn+ssh://dev.eclipse.org/svnroot/rt/org.eclipse.jetty/jetty/trunk@706 7e9141cc-0065-0410-87d8-b60c137991c4
This commit is contained in:
parent
2eb8343277
commit
e9c6245eb6
|
@ -227,6 +227,17 @@ public class IO
|
|||
out.write(buffer,0,len);
|
||||
}
|
||||
}
|
||||
else if (out instanceof PrintWriter)
|
||||
{
|
||||
PrintWriter pout=(PrintWriter)out;
|
||||
while (!pout.checkError())
|
||||
{
|
||||
len=in.read(buffer,0,bufferSize);
|
||||
if (len==-1)
|
||||
break;
|
||||
out.write(buffer,0,len);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
while (true)
|
||||
|
|
Loading…
Reference in New Issue