You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by ke...@apache.org on 2005/02/27 22:33:48 UTC

cvs commit: jakarta-tomcat-catalina/catalina/src/share/org/apache/coyote/tomcat5 OutputBuffer.java

keith       2005/02/27 13:33:48

  Modified:    catalina/src/share/org/apache/coyote/tomcat5 Tag: TOMCAT_5_0
                        OutputBuffer.java
  Log:
  Backport to 50 branch of fix to allow servlets to return
  multi-gb content-length headers
  
  - allow servlets to set content-length > Integer.MAX_VALUE via setHeader()
  - if servlet sets a content length in this manner, getContentLength will
    return -1 if cl > Integer.MAX_VALUE, so test getContentLengthLong to see
    if the cl was set.
  
  Revision  Changes    Path
  No                   revision
  No                   revision
  1.8.2.2   +1 -1      jakarta-tomcat-catalina/catalina/src/share/org/apache/coyote/tomcat5/Attic/OutputBuffer.java
  
  Index: OutputBuffer.java
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat-catalina/catalina/src/share/org/apache/coyote/tomcat5/Attic/OutputBuffer.java,v
  retrieving revision 1.8.2.1
  retrieving revision 1.8.2.2
  diff -u -r1.8.2.1 -r1.8.2.2
  --- OutputBuffer.java	18 Nov 2004 22:14:24 -0000	1.8.2.1
  +++ OutputBuffer.java	27 Feb 2005 21:33:48 -0000	1.8.2.2
  @@ -267,7 +267,7 @@
               return;
   
           if ((!coyoteResponse.isCommitted()) 
  -            && (coyoteResponse.getContentLength() == -1)) {
  +            && (coyoteResponse.getContentLengthLong() == -1)) {
               // Flushing the char buffer
               if (state == CHAR_STATE) {
                   cb.flushBuffer();
  
  
  

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