remm        01/12/03 11:55:29

  Modified:    catalina/src/share/org/apache/catalina/connector Tag:
                        tomcat_40_branch HttpResponseBase.java
  Log:
  - Port patch.
  - Remove dead code.
  - Suspend response after sendError and sendRedirect (simulates that the
    response has been sent from the application perspective).
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.37.2.3  +9 -21     
jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/connector/HttpResponseBase.java
  
  Index: HttpResponseBase.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/connector/HttpResponseBase.java,v
  retrieving revision 1.37.2.2
  retrieving revision 1.37.2.3
  diff -u -r1.37.2.2 -r1.37.2.3
  --- HttpResponseBase.java     2001/11/13 19:48:13     1.37.2.2
  +++ HttpResponseBase.java     2001/12/03 19:55:29     1.37.2.3
  @@ -1,7 +1,7 @@
   /*
  - * $Header: 
/home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/connector/HttpResponseBase.java,v
 1.37.2.2 2001/11/13 19:48:13 patrickl Exp $
  - * $Revision: 1.37.2.2 $
  - * $Date: 2001/11/13 19:48:13 $
  + * $Header: 
/home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/connector/HttpResponseBase.java,v
 1.37.2.3 2001/12/03 19:55:29 remm Exp $
  + * $Revision: 1.37.2.3 $
  + * $Date: 2001/12/03 19:55:29 $
    *
    * ====================================================================
    *
  @@ -101,7 +101,7 @@
    *
    * @author Craig R. McClanahan
    * @author Remy Maucherat
  - * @version $Revision: 1.37.2.2 $ $Date: 2001/11/13 19:48:13 $
  + * @version $Revision: 1.37.2.3 $ $Date: 2001/12/03 19:55:29 $
    */
   
   public class HttpResponseBase
  @@ -1044,23 +1044,8 @@
           // Clear any data content that has been buffered
           resetBuffer();
   
  -        // Cause the response to be committed
  -        /* Per spec clarification, no default content type is set
  -        String contentType = getContentType();
  -        if ((contentType == null) || "text/plain".equals(contentType))
  -            setContentType("text/html");
  -        */
  -
  -        // Temporarily comment out the following flush so that
  -        // default error reports can still set the content type
  -        // FIXME - this stuff needs to be refactored
  -        /*
  -        try {
  -            flushBuffer();
  -        } catch (IOException e) {
  -            ;
  -        }
  -        */
  +        // Cause the response to be finished (from the application perspective)
  +        setSuspended(true);
   
       }
   
  @@ -1094,6 +1079,9 @@
           } catch (IllegalArgumentException e) {
               setStatus(SC_NOT_FOUND);
           }
  +
  +        // Cause the response to be finished (from the application perspective)
  +        setSuspended(true);
   
       }
   
  
  
  

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to