commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sgoes...@apache.org
Subject svn commit: r785383 - /commons/proper/email/trunk/src/java/org/apache/commons/mail/HtmlEmail.java
Date Tue, 16 Jun 2009 20:36:22 GMT
Author: sgoeschl
Date: Tue Jun 16 20:36:22 2009
New Revision: 785383

URL: http://svn.apache.org/viewvc?rev=785383&view=rev
Log:
[EMAIL-87] Updated the comments

Modified:
    commons/proper/email/trunk/src/java/org/apache/commons/mail/HtmlEmail.java

Modified: commons/proper/email/trunk/src/java/org/apache/commons/mail/HtmlEmail.java
URL: http://svn.apache.org/viewvc/commons/proper/email/trunk/src/java/org/apache/commons/mail/HtmlEmail.java?rev=785383&r1=785382&r2=785383&view=diff
==============================================================================
--- commons/proper/email/trunk/src/java/org/apache/commons/mail/HtmlEmail.java (original)
+++ commons/proper/email/trunk/src/java/org/apache/commons/mail/HtmlEmail.java Tue Jun 16
20:36:22 2009
@@ -266,6 +266,9 @@
             URLDataSource urlDataSource = (URLDataSource) ii.getDataSource();
             // make sure the supplied URL points to the same thing
             // as the one already associated with this name.
+            // NOTE: Comparing URLs with URL.equals() is a blocking operation
+            // in the case of a network failure therefore we use
+            // url.toExternalForm().equals() here.
             if (url.toExternalForm().equals(urlDataSource.getURL().toExternalForm()))
             {
                 return ii.getCid();
@@ -276,10 +279,6 @@
                     + "' is already bound to URL " + urlDataSource.getURL()
                     + "; existing names cannot be rebound");
             }
-            // NOTE: Comparing URLs with URL.equals() is known to be
-            // inconsistent when dealing with virtual hosting over HTTP,
-            // but since these are almost always files on the local machine,
-            // using equals() should be sufficient.
         }
 
         // verify that the URL is valid



Mime
View raw message