costin      01/08/25 11:14:27

  Modified:    src/share/org/apache/tomcat/modules/generators
                        ErrorHandler.java
  Log:
  One more check for null
  
  Revision  Changes    Path
  1.17      +5 -1      
jakarta-tomcat/src/share/org/apache/tomcat/modules/generators/ErrorHandler.java
  
  Index: ErrorHandler.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/modules/generators/ErrorHandler.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -r1.16 -r1.17
  --- ErrorHandler.java 2001/08/24 02:24:19     1.16
  +++ ErrorHandler.java 2001/08/25 18:14:27     1.17
  @@ -168,7 +168,11 @@
        // XXX this log was intended to debug the status code generation.
        // it can be removed for all cases.
        if( code > 401 ) {// tuneme
  -         ctx.log( "Status code:" + code + " request:"  + req + " msg:" +
  +         if( ctx==null )
  +             cm.log( "Status code:" + code + " request:"  + req + " msg:" +
  +                  req.getAttribute("javax.servlet.error.message"));
  +         else
  +             ctx.log( "Status code:" + code + " request:"  + req + " msg:" +
                     req.getAttribute("javax.servlet.error.message"));
        }
        
  
  
  

Reply via email to