cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Carsten Ziegeler" <cziege...@s-und-n.de>
Subject RE: CocoonServlet.java patch
Date Wed, 09 Jan 2002 08:18:40 GMT
Hi Ihor,

thanks for your patch - it's applied.

Carsten

> -----Original Message-----
> From: Ihor Strutynskyj [mailto:ihor42@hotmail.com]
> Sent: Tuesday, January 08, 2002 8:48 PM
> To: cocoon-dev@xml.apache.org
> Subject: CocoonServlet.java patch
>
>
> Hi all,
> This is my first message to this list, so please forgive me if I offend
> someone.
> I'm working on integration of Cocoon2 service with Turbine2 and
> was reading
> CocoonServlet.java. I found several problems in this file. In function
> initLogger() the lines 566 and 567 (CVS version 1.1 2002/01/03) access
> uninitialized variable log (this.log). I think the patch should look like:
>
> --- CocoonServlet.java.orig     Thu Jan  3 04:31:20 2002
> +++ CocoonServlet.java  Tue Jan  8 10:50:22 2002
> @@ -563,8 +563,8 @@
>          if (this.servletContextPath == null) {
>              File logSCDir = new File(this.workDir, "log");
>              logSCDir.mkdirs();
> -            if (log.isWarnEnabled()) {
> -                this.log.warn("Setting servlet-context for LogKit to " +
> logSCDir);
> +            if (logger.isWarnEnabled()) {
> +                logger.warn("Setting servlet-context for LogKit to " +
> logSCDir);
>              }
>              subcontext.put("context-root", logSCDir.toString());
>          } else {
>
> The other thing I would like to mention is:
> Why org.apache.log.Logger.log.warn() (or .info(), .error(),
> .debug()) call
> is always wrapped with if (log.isWarnEnabled()) {}? The
> org.apache.log.Logger has already isXxxxEnabled() wrappers in
> corresponding
> xxxx() functions. The code would look much simpler without those wrappers.
>
> Ihor.
>
> _________________________________________________________________
> Get your FREE download of MSN Explorer at
> http://explorer.msn.com/intl.asp.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
> For additional commands, email: cocoon-dev-help@xml.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org


Mime
View raw message