Author: markt
Date: Mon Dec 15 12:22:01 2014
New Revision: 1645632
URL: http://svn.apache.org/r1645632
Log:
Simplify
Modified:
tomcat/trunk/java/org/apache/juli/logging/DirectJDKLog.java
Modified: tomcat/trunk/java/org/apache/juli/logging/DirectJDKLog.java
URL:
http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/juli/logging/DirectJDKLog.java?rev=1645632&r1=1645631&r2=1645632&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/juli/logging/DirectJDKLog.java (original)
+++ tomcat/trunk/java/org/apache/juli/logging/DirectJDKLog.java Mon Dec 15
12:22:01 2014
@@ -50,11 +50,10 @@ class DirectJDKLog implements Log {
// it is also possible that the user modified
jre/lib/logging.properties -
// but that's really stupid in most cases
Logger root=Logger.getLogger("");
- Handler handlers[]=root.getHandlers();
- for( int i=0; i< handlers.length; i++ ) {
+ for (Handler handler : root.getHandlers()) {
// I only care about console - that's what's used in
default config anyway
- if( handlers[i] instanceof ConsoleHandler ) {
- handlers[i].setFormatter(fmt);
+ if (handler instanceof ConsoleHandler) {
+ handler.setFormatter(fmt);
}
}
} catch( Throwable t ) {
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]