tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From r...@apache.org
Subject cvs commit: jakarta-tomcat-connectors/coyote/src/java/org/apache/coyote/tomcat5 CoyoteOutputStream.java CoyoteResponse.java OutputBuffer.java
Date Tue, 05 Nov 2002 18:44:56 GMT
remm        2002/11/05 10:44:55

  Modified:    coyote/src/java/org/apache/coyote/tomcat5
                        CoyoteOutputStream.java CoyoteResponse.java
                        OutputBuffer.java
  Log:
  - Clean up writer and output stream handling. close will now finish the response
    on both the output stream and the writer.
  - This is relatively experimental, but appears to be working fine.
  
  Revision  Changes    Path
  1.2       +2 -6      jakarta-tomcat-connectors/coyote/src/java/org/apache/coyote/tomcat5/CoyoteOutputStream.java
  
  Index: CoyoteOutputStream.java
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat-connectors/coyote/src/java/org/apache/coyote/tomcat5/CoyoteOutputStream.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- CoyoteOutputStream.java	4 Aug 2002 19:39:49 -0000	1.1
  +++ CoyoteOutputStream.java	5 Nov 2002 18:44:55 -0000	1.2
  @@ -116,17 +116,13 @@
        */
       public void flush()
           throws IOException {
  -        if (ob.flushCharsNeeded())
  -            ob.flushChars();
  -        ob.flushBytes();
  +        ob.flush();
       }
   
   
       public void close()
           throws IOException {
  -        if (ob.flushCharsNeeded())
  -            ob.flushChars();
  -        ob.flushBytes();
  +        ob.close();
       }
   
   
  
  
  
  1.10      +4 -5      jakarta-tomcat-connectors/coyote/src/java/org/apache/coyote/tomcat5/CoyoteResponse.java
  
  Index: CoyoteResponse.java
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat-connectors/coyote/src/java/org/apache/coyote/tomcat5/CoyoteResponse.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -r1.9 -r1.10
  --- CoyoteResponse.java	10 Oct 2002 09:45:30 -0000	1.9
  +++ CoyoteResponse.java	5 Nov 2002 18:44:55 -0000	1.10
  @@ -501,7 +501,6 @@
           } catch(Throwable t) {
   	    t.printStackTrace();
           }
  -        coyoteResponse.finish();
       }
   
   
  
  
  
  1.2       +4 -0      jakarta-tomcat-connectors/coyote/src/java/org/apache/coyote/tomcat5/OutputBuffer.java
  
  Index: OutputBuffer.java
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat-connectors/coyote/src/java/org/apache/coyote/tomcat5/OutputBuffer.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- OutputBuffer.java	4 Aug 2002 19:39:49 -0000	1.1
  +++ OutputBuffer.java	5 Nov 2002 18:44:55 -0000	1.2
  @@ -301,6 +301,8 @@
       public void close()
           throws IOException {
   
  +        if (closed)
  +            return;
           if (suspended)
               return;
   
  @@ -320,6 +322,8 @@
   
           flush();
           closed = true;
  +
  +        coyoteResponse.finish();
   
       }
   
  
  
  

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


Mime
View raw message