This is an automated email from the ASF dual-hosted git repository.

ggregory pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/logging-log4j2.git


The following commit(s) were added to refs/heads/master by this push:
     new 421ed28  No need to nest in else clause.
421ed28 is described below

commit 421ed2821b24aa078c742669cc8c522300af1bfd
Author: Gary Gregory <[email protected]>
AuthorDate: Thu Nov 29 18:43:07 2018 -0700

    No need to nest in else clause.
---
 .../logging/log4j/core/appender/rolling/RollingFileManager.java       | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git 
a/log4j-core/src/main/java/org/apache/logging/log4j/core/appender/rolling/RollingFileManager.java
 
b/log4j-core/src/main/java/org/apache/logging/log4j/core/appender/rolling/RollingFileManager.java
index 884b6d5..0671854 100644
--- 
a/log4j-core/src/main/java/org/apache/logging/log4j/core/appender/rolling/RollingFileManager.java
+++ 
b/log4j-core/src/main/java/org/apache/logging/log4j/core/appender/rolling/RollingFileManager.java
@@ -36,7 +36,6 @@ import 
java.util.concurrent.atomic.AtomicReferenceFieldUpdater;
 
 import org.apache.logging.log4j.core.Layout;
 import org.apache.logging.log4j.core.LifeCycle;
-import org.apache.logging.log4j.core.LifeCycle2;
 import org.apache.logging.log4j.core.LogEvent;
 import org.apache.logging.log4j.core.LoggerContext;
 import org.apache.logging.log4j.core.appender.ConfigurationFactoryData;
@@ -624,9 +623,8 @@ public class RollingFileManager extends FileManager {
                 FileTime fileTime = attrs.creationTime();
                 if (fileTime.compareTo(EPOCH) > 0) {
                     return fileTime.toMillis();
-                } else {
-                    LOGGER.info("Unable to obtain file creation time for " + 
file.getAbsolutePath());
                 }
+                LOGGER.info("Unable to obtain file creation time for " + 
file.getAbsolutePath());
             } catch (Exception ex) {
                 LOGGER.info("Unable to calculate file creation time for " + 
file.getAbsolutePath() + ": " + ex.getMessage());
             }

Reply via email to