hc-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s...@apache.org
Subject svn commit: r1174784 - /httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/impl/client/DefaultRequestDirector.java
Date Fri, 23 Sep 2011 14:07:27 GMT
Author: sebb
Date: Fri Sep 23 14:07:26 2011
New Revision: 1174784

URL: http://svn.apache.org/viewvc?rev=1174784&view=rev
Log:
isDebugEnabled can only be true if isInfoEnabled is true, so don't perform a useless check
Also might as well merge the other log.info into the block

Modified:
    httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/impl/client/DefaultRequestDirector.java

Modified: httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/impl/client/DefaultRequestDirector.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/impl/client/DefaultRequestDirector.java?rev=1174784&r1=1174783&r2=1174784&view=diff
==============================================================================
--- httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/impl/client/DefaultRequestDirector.java
(original)
+++ httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/impl/client/DefaultRequestDirector.java
Fri Sep 23 14:07:26 2011
@@ -584,11 +584,11 @@ public class DefaultRequestDirector impl
                         this.log.info("I/O exception ("+ ex.getClass().getName() +
                                 ") caught when connecting to the target host: "
                                 + ex.getMessage());
+                        if (this.log.isDebugEnabled()) {
+                            this.log.debug(ex.getMessage(), ex);
+                        }
+                        this.log.info("Retrying connect");
                     }
-                    if (this.log.isDebugEnabled()) {
-                        this.log.debug(ex.getMessage(), ex);
-                    }
-                    this.log.info("Retrying connect");
                 } else {
                     throw ex;
                 }



Mime
View raw message