logging-log4j-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From carn...@apache.org
Subject svn commit: r427681 - /logging/log4j/branches/v1_2-branch/src/java/org/apache/log4j/RollingFileAppender.java
Date Tue, 01 Aug 2006 19:15:20 GMT
Author: carnold
Date: Tue Aug  1 12:15:20 2006
New Revision: 427681

URL: http://svn.apache.org/viewvc?rev=427681&view=rev
Log:
Bug 31003: RollingFileAppender, if removed, can cause null pointer exceptions

Modified:
    logging/log4j/branches/v1_2-branch/src/java/org/apache/log4j/RollingFileAppender.java

Modified: logging/log4j/branches/v1_2-branch/src/java/org/apache/log4j/RollingFileAppender.java
URL: http://svn.apache.org/viewvc/logging/log4j/branches/v1_2-branch/src/java/org/apache/log4j/RollingFileAppender.java?rev=427681&r1=427680&r2=427681&view=diff
==============================================================================
--- logging/log4j/branches/v1_2-branch/src/java/org/apache/log4j/RollingFileAppender.java
(original)
+++ logging/log4j/branches/v1_2-branch/src/java/org/apache/log4j/RollingFileAppender.java
Tue Aug  1 12:15:20 2006
@@ -118,7 +118,9 @@
     File target;
     File file;
 
-    LogLog.debug("rolling over count=" + ((CountingQuietWriter) qw).getCount());
+    if (qw != null) {
+    	LogLog.debug("rolling over count=" + ((CountingQuietWriter) qw).getCount());
+    }
     LogLog.debug("maxBackupIndex="+maxBackupIndex);
 
     // If maxBackups <= 0, then there is no file renaming to be done.



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


Mime
View raw message