logging-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ggreg...@apache.org
Subject svn commit: r1501381 - /logging/log4j/log4j2/trunk/core/src/main/java/org/apache/logging/log4j/core/appender/db/jdbc/ColumnConfig.java
Date Tue, 09 Jul 2013 17:08:43 GMT
Author: ggregory
Date: Tue Jul  9 17:08:43 2013
New Revision: 1501381

URL: http://svn.apache.org/r1501381
Log:
The pattern 'str != null && Boolean.parseBoolean(str)' is the same as just 'Boolean.parseBoolean(str)'
because Boolean.parseBoolean(String) checks for null.

Modified:
    logging/log4j/log4j2/trunk/core/src/main/java/org/apache/logging/log4j/core/appender/db/jdbc/ColumnConfig.java

Modified: logging/log4j/log4j2/trunk/core/src/main/java/org/apache/logging/log4j/core/appender/db/jdbc/ColumnConfig.java
URL: http://svn.apache.org/viewvc/logging/log4j/log4j2/trunk/core/src/main/java/org/apache/logging/log4j/core/appender/db/jdbc/ColumnConfig.java?rev=1501381&r1=1501380&r2=1501381&view=diff
==============================================================================
--- logging/log4j/log4j2/trunk/core/src/main/java/org/apache/logging/log4j/core/appender/db/jdbc/ColumnConfig.java
(original)
+++ logging/log4j/log4j2/trunk/core/src/main/java/org/apache/logging/log4j/core/appender/db/jdbc/ColumnConfig.java
Tue Jul  9 17:08:43 2013
@@ -113,7 +113,7 @@ public final class ColumnConfig {
         final boolean isLiteralValue = literalValue != null && literalValue.length()
> 0;
         final boolean isEventTimestamp = Boolean.parseBoolean(eventTimestamp);
         final boolean isUnicode = Strings.isEmpty(unicode) || Boolean.parseBoolean(unicode);
-        final boolean isClob = clob != null && Boolean.parseBoolean(clob);
+        final boolean isClob = Boolean.parseBoolean(clob);
 
         if ((isPattern && isLiteralValue) || (isPattern && isEventTimestamp)
|| (isLiteralValue && isEventTimestamp)) {
             LOGGER.error("The pattern, literal, and isEventTimestamp attributes are mutually
exclusive.");



Mime
View raw message