tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lar...@apache.org
Subject cvs commit: jakarta-tomcat/src/share/org/apache/tomcat/core Response.java
Date Wed, 23 May 2001 03:09:28 GMT
larryi      01/05/22 20:09:26

  Modified:    src/share/org/apache/tomcat/core Response.java
  Log:
  Update setBufferSize() to use OutputBuffer.isNew() to detect if buffer has
  been written. Fixes Watchdog servlet failure.
  
  Revision  Changes    Path
  1.51      +1 -8      jakarta-tomcat/src/share/org/apache/tomcat/core/Response.java
  
  Index: Response.java
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/core/Response.java,v
  retrieving revision 1.50
  retrieving revision 1.51
  diff -u -r1.50 -r1.51
  --- Response.java	2001/02/26 04:34:16	1.50
  +++ Response.java	2001/05/23 03:09:21	1.51
  @@ -382,14 +382,7 @@
       }
   
       public void setBufferSize(int size) throws IllegalStateException {
  -	// Force the PrintWriter to flush the data to the OutputStream.
  -	//	if (usingWriter == true && writer != null ) writer.flush();
  -        try{
  -            oBuffer.flushChars();
  -        }catch(IOException ex){
  -                ;
  -        }
  -	if( oBuffer.getBytesWritten() >0) {
  +	if( !oBuffer.isNew() ) {
   	    throw new IllegalStateException ( sm.getString("servletOutputStreamImpl.setbuffer.ise"));
   	}
   	oBuffer.setBufferSize( size );
  
  
  

Mime
View raw message