logging-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ggreg...@apache.org
Subject svn commit: r1501348 - /logging/log4j/log4j2/trunk/core/src/main/java/org/apache/logging/log4j/core/appender/FailoverAppender.java
Date Tue, 09 Jul 2013 15:50:37 GMT
Author: ggregory
Date: Tue Jul  9 15:50:36 2013
New Revision: 1501348

URL: http://svn.apache.org/r1501348
Log:
Avoid NumberFormatException if interval is an empty String.

Modified:
    logging/log4j/log4j2/trunk/core/src/main/java/org/apache/logging/log4j/core/appender/FailoverAppender.java

Modified: logging/log4j/log4j2/trunk/core/src/main/java/org/apache/logging/log4j/core/appender/FailoverAppender.java
URL: http://svn.apache.org/viewvc/logging/log4j/log4j2/trunk/core/src/main/java/org/apache/logging/log4j/core/appender/FailoverAppender.java?rev=1501348&r1=1501347&r2=1501348&view=diff
==============================================================================
--- logging/log4j/log4j2/trunk/core/src/main/java/org/apache/logging/log4j/core/appender/FailoverAppender.java
(original)
+++ logging/log4j/log4j2/trunk/core/src/main/java/org/apache/logging/log4j/core/appender/FailoverAppender.java
Tue Jul  9 15:50:36 2013
@@ -33,6 +33,7 @@ import org.apache.logging.log4j.core.con
 import org.apache.logging.log4j.core.config.plugins.PluginElement;
 import org.apache.logging.log4j.core.config.plugins.PluginFactory;
 import org.apache.logging.log4j.core.helpers.Constants;
+import org.apache.logging.log4j.core.helpers.Strings;
 
 /**
  * The FailoverAppender will capture exceptions in an Appender and then route the event
@@ -206,7 +207,7 @@ public final class FailoverAppender<T ex
         }
 
         int retryInterval;
-        if (interval == null) {
+        if (Strings.isEmpty(interval)) {
             retryInterval = DEFAULT_INTERVAL;
         } else {
             try {



Mime
View raw message