cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ba...@locus.apache.org
Subject cvs commit: xml-cocoon/src/org/apache/cocoon Engine.java
Date Thu, 03 Feb 2000 08:09:14 GMT
balld       00/02/03 00:09:14

  Modified:    src/org/apache/cocoon Engine.java
  Log:
  Submitted from: Mike Engelhard <mengelhart@earthtrip.com>
  Reviewed by: Donald Ball <balld@webslingerZ.com>
  wrapped call to out.getWriter() in try/catch block so cocoon can work with
  the RequestDispatcher stuff in JSDK 2.2. it's known to work in tomcat and
  apache-jserv, can't imagine anything going wrong elsewhere.
  
  Revision  Changes    Path
  1.12      +12 -4     xml-cocoon/src/org/apache/cocoon/Engine.java
  
  Index: Engine.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon/src/org/apache/cocoon/Engine.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -r1.11 -r1.12
  --- Engine.java	2000/01/31 21:53:12	1.11
  +++ Engine.java	2000/02/03 08:09:14	1.12
  @@ -1,4 +1,4 @@
  -/*-- $Id: Engine.java,v 1.11 2000/01/31 21:53:12 stefano Exp $ --
  +/*-- $Id: Engine.java,v 1.12 2000/02/03 08:09:14 balld Exp $ --
   
    ============================================================================
                      The Apache Software License, Version 1.1
  @@ -72,7 +72,7 @@
    * This class implements the engine that does all the document processing.
    *
    * @author <a href="mailto:stefano@apache.org">Stefano Mazzocchi</a>
  - * @version $Revision: 1.11 $ $Date: 2000/01/31 21:53:12 $
  + * @version $Revision: 1.12 $ $Date: 2000/02/03 08:09:14 $
    */
   
   public class Engine implements Defaults {
  @@ -311,7 +311,15 @@
               response.setContentType(page.getContentType());
   
               // get the output writer
  -            PrintWriter out = response.getWriter();
  +            PrintWriter out = null;
  +			try {
  +				out = response.getWriter();
  +			} catch (IllegalStateException e) {
  +				// we don't want to write to this or cache this document since
  +				// presumably it is not complete so lets return
  +				// from this call to handle()
  +				return;
  +			}
   
               // send the page
               out.println(page.getContent());
  @@ -366,4 +374,4 @@
           }
           return table;
       }
  -}
  \ No newline at end of file
  +}
  
  
  

Mime
View raw message